From imp at bsdimp.com Sun Nov 1 01:08:56 2009
From: imp at bsdimp.com (M. Warner Losh)
Date: Sun Nov 1 01:09:07 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To: <200910311035.n9VAZfIb082932@svn.freebsd.org>
References: <200910311035.n9VAZfIb082932@svn.freebsd.org>
Message-ID: <20091031.190353.-332187386.imp@bsdimp.com>
In message: <200910311035.n9VAZfIb082932@svn.freebsd.org>
Ed Schouten writes:
: Author: ed
: Date: Sat Oct 31 10:35:41 2009
: New Revision: 198706
: URL: http://svn.freebsd.org/changeset/base/198706
:
: Log:
: Turn unused structure fields of cdevsw into spares.
:
: d_uid, d_gid and d_mode are unused, because permissions are stored in
: cdevpriv nowadays. d_kind doesn't seem to be used at all. We no longer
: keep a list of cdevsw's, so d_list is also unused.
:
: uid_t and gid_t are 32 bits, but mode_t is 16 bits, Because of alignment
: constraints of d_kind, we can safely turn it into three 32-bit integers.
: d_kind and d_list is equal in size to three pointers.
:
: Discussed with: kib
Don't we need a D_VERSION bump for this?
Warner
: Modified:
: head/sys/sys/conf.h
:
: Modified: head/sys/sys/conf.h
: ==============================================================================
: --- head/sys/sys/conf.h Sat Oct 31 09:03:48 2009 (r198705)
: +++ head/sys/sys/conf.h Sat Oct 31 10:35:41 2009 (r198706)
: @@ -210,15 +210,13 @@ struct cdevsw {
: d_kqfilter_t *d_kqfilter;
: d_purge_t *d_purge;
: d_mmap_single_t *d_mmap_single;
: - uid_t d_uid;
: - gid_t d_gid;
: - mode_t d_mode;
: - const char *d_kind;
: +
: + int32_t d_spare0[3];
: + void *d_spare1[3];
:
: /* These fields should not be messed with by drivers */
: - LIST_ENTRY(cdevsw) d_list;
: LIST_HEAD(, cdev) d_devs;
: - int d_spare3;
: + int d_spare2;
: union {
: struct cdevsw *gianttrick;
: SLIST_ENTRY(cdevsw) postfree_list;
:
From ed at 80386.nl Sun Nov 1 01:12:13 2009
From: ed at 80386.nl (Ed Schouten)
Date: Sun Nov 1 01:12:20 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To: <20091031.190353.-332187386.imp@bsdimp.com>
References: <200910311035.n9VAZfIb082932@svn.freebsd.org>
<20091031.190353.-332187386.imp@bsdimp.com>
Message-ID: <20091101011212.GG1293@hoeg.nl>
Hi Warner,
* M. Warner Losh wrote:
> Don't we need a D_VERSION bump for this?
No, we don't. All these fields are not used by drivers, just some old
version of the devfs code. I made sure struct cdevsw didn't change in
size, so there should be no API nor ABI conflicts.
--
Ed Schouten
WWW: http://80386.nl/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091101/6e42fac5/attachment.pgp
From imp at bsdimp.com Sun Nov 1 03:02:36 2009
From: imp at bsdimp.com (M. Warner Losh)
Date: Sun Nov 1 03:02:48 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To: <20091101011212.GG1293@hoeg.nl>
References: <200910311035.n9VAZfIb082932@svn.freebsd.org>
<20091031.190353.-332187386.imp@bsdimp.com>
<20091101011212.GG1293@hoeg.nl>
Message-ID: <20091031.205704.-79135471.imp@bsdimp.com>
In message: <20091101011212.GG1293@hoeg.nl>
Ed Schouten writes:
: Hi Warner,
:
: * M. Warner Losh wrote:
: > Don't we need a D_VERSION bump for this?
:
: No, we don't. All these fields are not used by drivers, just some old
: version of the devfs code. I made sure struct cdevsw didn't change in
: size, so there should be no API nor ABI conflicts.
On all platforms?
A version bump is trivial...
Warner
From rdivacky at FreeBSD.org Sun Nov 1 08:20:30 2009
From: rdivacky at FreeBSD.org (Roman Divacky)
Date: Sun Nov 1 08:20:36 2009
Subject: svn commit: r198741 - head
Message-ID: <200911010820.nA18KUj4017208@svn.freebsd.org>
Author: rdivacky
Date: Sun Nov 1 08:20:30 2009
New Revision: 198741
URL: http://svn.freebsd.org/changeset/base/198741
Log:
Replace -iprefix with -isystem. We only need alternative header
files search path and thus -isystem is sufficient. -iprefix is
meant to do something entirely different.
Approved by: ed (mentor)
OKed by: ru, kan
Tested by: make universe
Modified:
head/Makefile.inc1
Modified: head/Makefile.inc1
==============================================================================
--- head/Makefile.inc1 Sun Nov 1 04:57:41 2009 (r198740)
+++ head/Makefile.inc1 Sun Nov 1 08:20:30 2009 (r198741)
@@ -272,7 +272,7 @@ LIB32CPUFLAGS= -march=i686 -mmmx -msse -
LIB32CPUFLAGS= -march=${TARGET_CPUTYPE}
.endif
LIB32FLAGS= -m32 ${LIB32CPUFLAGS} -mfancy-math-387 -DCOMPAT_32BIT \
- -iprefix ${LIB32TMP}/usr/ \
+ -isystem ${LIB32TMP}/usr/include/ \
-L${LIB32TMP}/usr/lib32 \
-B${LIB32TMP}/usr/lib32
From alc at FreeBSD.org Sun Nov 1 08:45:45 2009
From: alc at FreeBSD.org (Alan Cox)
Date: Sun Nov 1 08:45:57 2009
Subject: svn commit: r198742 - in stable/7/sys: . amd64/include arm/include
contrib/pf i386/include ia64/include kern powerpc/include
sparc64/include sun4v/include sys
Message-ID: <200911010845.nA18jice017741@svn.freebsd.org>
Author: alc
Date: Sun Nov 1 08:45:44 2009
New Revision: 198742
URL: http://svn.freebsd.org/changeset/base/198742
Log:
MFC r197316
Add a new sysctl for reporting all of the supported page sizes.
Modified:
stable/7/sys/ (props changed)
stable/7/sys/amd64/include/param.h
stable/7/sys/arm/include/param.h
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/i386/include/param.h
stable/7/sys/ia64/include/param.h
stable/7/sys/kern/kern_mib.c
stable/7/sys/powerpc/include/param.h
stable/7/sys/sparc64/include/param.h
stable/7/sys/sun4v/include/param.h
stable/7/sys/sys/systm.h
Modified: stable/7/sys/amd64/include/param.h
==============================================================================
--- stable/7/sys/amd64/include/param.h Sun Nov 1 08:20:30 2009 (r198741)
+++ stable/7/sys/amd64/include/param.h Sun Nov 1 08:45:44 2009 (r198742)
@@ -115,6 +115,8 @@
#define NBPML4 (1ul<flags & SCTL_MASK32) {
+ /*
+ * Recreate the "pagesizes" array with 32-bit elements. Truncate
+ * any page size greater than UINT32_MAX to zero.
+ */
+ for (i = 0; i < MAXPAGESIZES; i++)
+ pagesizes32[i] = (uint32_t)pagesizes[i];
+
+ error = SYSCTL_OUT(req, pagesizes32, sizeof(pagesizes32));
+ } else
+#endif
+ error = SYSCTL_OUT(req, pagesizes, sizeof(pagesizes));
+ return (error);
+}
+SYSCTL_PROC(_hw, OID_AUTO, pagesizes, CTLTYPE_ULONG | CTLFLAG_RD,
+ NULL, 0, sysctl_hw_pagesizes, "LU", "Supported page sizes");
+
static char machine_arch[] = MACHINE_ARCH;
SYSCTL_STRING(_hw, HW_MACHINE_ARCH, machine_arch, CTLFLAG_RD,
machine_arch, 0, "System architecture");
Modified: stable/7/sys/powerpc/include/param.h
==============================================================================
--- stable/7/sys/powerpc/include/param.h Sun Nov 1 08:20:30 2009 (r198741)
+++ stable/7/sys/powerpc/include/param.h Sun Nov 1 08:45:44 2009 (r198742)
@@ -81,6 +81,8 @@
#define PAGE_MASK (PAGE_SIZE - 1)
#define NPTEPG (PAGE_SIZE/(sizeof (pt_entry_t)))
+#define MAXPAGESIZES 1 /* maximum number of supported page sizes */
+
#ifndef KSTACK_PAGES
#define KSTACK_PAGES 4 /* includes pcb */
#endif
Modified: stable/7/sys/sparc64/include/param.h
==============================================================================
--- stable/7/sys/sparc64/include/param.h Sun Nov 1 08:20:30 2009 (r198741)
+++ stable/7/sys/sparc64/include/param.h Sun Nov 1 08:45:44 2009 (r198742)
@@ -107,6 +107,8 @@
#define PAGE_SIZE_MAX PAGE_SIZE_4M
#define PAGE_MASK_MAX PAGE_MASK_4M
+#define MAXPAGESIZES 1 /* maximum number of supported page sizes */
+
#ifndef KSTACK_PAGES
#define KSTACK_PAGES 4 /* pages of kernel stack (with pcb) */
#endif
Modified: stable/7/sys/sun4v/include/param.h
==============================================================================
--- stable/7/sys/sun4v/include/param.h Sun Nov 1 08:20:30 2009 (r198741)
+++ stable/7/sys/sun4v/include/param.h Sun Nov 1 08:45:44 2009 (r198742)
@@ -102,6 +102,8 @@
#define PAGE_SIZE_MAX PAGE_SIZE_4M
#define PAGE_MASK_MAX PAGE_MASK_4M
+#define MAXPAGESIZES 1 /* maximum number of supported page sizes */
+
#ifndef KSTACK_PAGES
#define KSTACK_PAGES 4 /* pages of kernel stack (with pcb) */
#endif
Modified: stable/7/sys/sys/systm.h
==============================================================================
--- stable/7/sys/sys/systm.h Sun Nov 1 08:20:30 2009 (r198741)
+++ stable/7/sys/sys/systm.h Sun Nov 1 08:45:44 2009 (r198742)
@@ -60,6 +60,7 @@ extern u_int nselcoll; /* select collis
extern struct mtx sellock; /* select lock variable */
extern struct cv selwait; /* select conditional variable */
+extern u_long pagesizes[]; /* supported page sizes */
extern long physmem; /* physical memory */
extern long realmem; /* 'real' memory */
From alc at FreeBSD.org Sun Nov 1 08:48:31 2009
From: alc at FreeBSD.org (Alan Cox)
Date: Sun Nov 1 08:48:38 2009
Subject: svn commit: r198743 - in stable/7/sys: . amd64/amd64 contrib/pf
i386/i386
Message-ID: <200911010848.nA18mUNQ017838@svn.freebsd.org>
Author: alc
Date: Sun Nov 1 08:48:30 2009
New Revision: 198743
URL: http://svn.freebsd.org/changeset/base/198743
Log:
MFC r197317
When superpages are enabled, add the 2 or 4MB page size to the array of
supported page sizes.
Modified:
stable/7/sys/ (props changed)
stable/7/sys/amd64/amd64/pmap.c
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/i386/i386/pmap.c
Modified: stable/7/sys/amd64/amd64/pmap.c
==============================================================================
--- stable/7/sys/amd64/amd64/pmap.c Sun Nov 1 08:45:44 2009 (r198742)
+++ stable/7/sys/amd64/amd64/pmap.c Sun Nov 1 08:48:30 2009 (r198743)
@@ -666,6 +666,11 @@ pmap_init(void)
* Are large page mappings enabled?
*/
TUNABLE_INT_FETCH("vm.pmap.pg_ps_enabled", &pg_ps_enabled);
+ if (pg_ps_enabled) {
+ KASSERT(MAXPAGESIZES > 1 && pagesizes[1] == 0,
+ ("pmap_init: can't assign to pagesizes[1]"));
+ pagesizes[1] = NBPDR;
+ }
/*
* Calculate the size of the pv head table for superpages.
Modified: stable/7/sys/i386/i386/pmap.c
==============================================================================
--- stable/7/sys/i386/i386/pmap.c Sun Nov 1 08:45:44 2009 (r198742)
+++ stable/7/sys/i386/i386/pmap.c Sun Nov 1 08:48:30 2009 (r198743)
@@ -666,6 +666,11 @@ pmap_init(void)
* Are large page mappings enabled?
*/
TUNABLE_INT_FETCH("vm.pmap.pg_ps_enabled", &pg_ps_enabled);
+ if (pg_ps_enabled) {
+ KASSERT(MAXPAGESIZES > 1 && pagesizes[1] == 0,
+ ("pmap_init: can't assign to pagesizes[1]"));
+ pagesizes[1] = NBPDR;
+ }
/*
* Calculate the size of the pv head table for superpages.
From mav at FreeBSD.org Sun Nov 1 10:01:39 2009
From: mav at FreeBSD.org (Alexander Motin)
Date: Sun Nov 1 10:01:45 2009
Subject: svn commit: r198744 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris conf contrib/dev/acpica contrib/pf
dev/xen/xenpci
Message-ID: <200911011001.nA1A1dQn019268@svn.freebsd.org>
Author: mav
Date: Sun Nov 1 10:01:39 2009
New Revision: 198744
URL: http://svn.freebsd.org/changeset/base/198744
Log:
MFC rev. 198623:
Add missing ATA kernel options dependencies.
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/conf/files
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/conf/files
==============================================================================
--- stable/8/sys/conf/files Sun Nov 1 08:48:30 2009 (r198743)
+++ stable/8/sys/conf/files Sun Nov 1 10:01:39 2009 (r198744)
@@ -517,14 +517,14 @@ dev/ata/chipsets/ata-highpoint.c optiona
dev/ata/chipsets/ata-intel.c optional ata pci | ataintel
dev/ata/chipsets/ata-ite.c optional ata pci | ataite
dev/ata/chipsets/ata-jmicron.c optional ata pci | atajmicron
-dev/ata/chipsets/ata-marvell.c optional ata pci | atamarvell
+dev/ata/chipsets/ata-marvell.c optional ata pci | atamarvell | ataadaptec
dev/ata/chipsets/ata-micron.c optional ata pci | atamicron
dev/ata/chipsets/ata-national.c optional ata pci | atanational
dev/ata/chipsets/ata-netcell.c optional ata pci | atanetcell
dev/ata/chipsets/ata-nvidia.c optional ata pci | atanvidia
dev/ata/chipsets/ata-promise.c optional ata pci | atapromise
dev/ata/chipsets/ata-serverworks.c optional ata pci | ataserverworks
-dev/ata/chipsets/ata-siliconimage.c optional ata pci | atasiliconimage
+dev/ata/chipsets/ata-siliconimage.c optional ata pci | atasiliconimage | ataati
dev/ata/chipsets/ata-sis.c optional ata pci | atasis
dev/ata/chipsets/ata-via.c optional ata pci | atavia
dev/ata/ata-disk.c optional atadisk
From ed at FreeBSD.org Sun Nov 1 10:30:31 2009
From: ed at FreeBSD.org (Ed Schouten)
Date: Sun Nov 1 10:30:42 2009
Subject: svn commit: r198745 - in stable/8: etc sys sys/amd64/include/xen
sys/cddl/contrib/opensolaris sys/contrib/dev/acpica
sys/contrib/pf sys/dev/syscons sys/dev/xen/xenpci sys/kern
sys/sys usr.sbin/jail
Message-ID: <200911011030.nA1AUVsN019962@svn.freebsd.org>
Author: ed
Date: Sun Nov 1 10:30:30 2009
New Revision: 198745
URL: http://svn.freebsd.org/changeset/base/198745
Log:
MFC various commits back to stable/8:
SVN r197174:
Make sure we never place the cursor outside the screen.
For some vague reason, it may be possible that scp->cursor_pos exceeds
scp->ysize * scp->xsize. This means that teken_set_cursor() may get
called with an invalid position. Just ignore the old cursor position in
this case.
Reported by: Paul B. Mahol
SVN r198213:
Make lock devices work properly.
It turned out I did add the code to use the init state devices to set
the termios structure when opening the device, but it seems I totally
forgot to add the bits required to force the actual locking of flags
through the lock state devices.
Reported by: ru
SVN r198215, r198217:
Fix a typo in the jail(8) manpage.
Submitted by: Jille Timmermans
SVN r198216:
Fix qouting in a comment, to make it look more consistent
Submitted by: Jille Timmermans
SVN r198223:
Properly set the low watermarks when reducing the baud rate.
Now that buffers are deallocated lazily, we should not use
tty*q_getsize() to obtain the buffer size to calculate the low
watermarks. Doing this may cause the watermark to be placed outside the
typical buffer size.
This caused some regressions after my previous commit to the TTY code,
which allows pseudo-devices to resize the buffers as well.
Reported by: yongari, dougb
Modified:
stable/8/etc/ (props changed)
stable/8/etc/rc.subr
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/syscons/scterm-teken.c
stable/8/sys/dev/xen/xenpci/ (props changed)
stable/8/sys/kern/tty.c
stable/8/sys/sys/ttyqueue.h
stable/8/usr.sbin/jail/ (props changed)
stable/8/usr.sbin/jail/jail.8
Modified: stable/8/etc/rc.subr
==============================================================================
--- stable/8/etc/rc.subr Sun Nov 1 10:01:39 2009 (r198744)
+++ stable/8/etc/rc.subr Sun Nov 1 10:30:30 2009 (r198745)
@@ -565,7 +565,7 @@ run_rc_command()
rc_fast=yes
rc_quiet=yes
;;
- force*) # "force prefix; always run
+ force*) # "force" prefix; always run
rc_force=yes
_rc_prefix=force
rc_arg=${rc_arg#${_rc_prefix}}
Modified: stable/8/sys/dev/syscons/scterm-teken.c
==============================================================================
--- stable/8/sys/dev/syscons/scterm-teken.c Sun Nov 1 10:01:39 2009 (r198744)
+++ stable/8/sys/dev/syscons/scterm-teken.c Sun Nov 1 10:30:30 2009 (r198745)
@@ -130,9 +130,12 @@ scteken_init(scr_stat *scp, void **softc
tp.tp_col = scp->xsize;
teken_set_winsize(&ts->ts_teken, &tp);
- tp.tp_row = scp->cursor_pos / scp->xsize;
- tp.tp_col = scp->cursor_pos % scp->xsize;
- teken_set_cursor(&ts->ts_teken, &tp);
+ if (scp->cursor_pos < scp->ysize * scp->xsize) {
+ /* Valid old cursor position. */
+ tp.tp_row = scp->cursor_pos / scp->xsize;
+ tp.tp_col = scp->cursor_pos % scp->xsize;
+ teken_set_cursor(&ts->ts_teken, &tp);
+ }
break;
}
Modified: stable/8/sys/kern/tty.c
==============================================================================
--- stable/8/sys/kern/tty.c Sun Nov 1 10:01:39 2009 (r198744)
+++ stable/8/sys/kern/tty.c Sun Nov 1 10:30:30 2009 (r198745)
@@ -109,14 +109,14 @@ tty_watermarks(struct tty *tp)
ttyinq_setsize(&tp->t_inq, tp, bs);
/* Set low watermark at 10% (when 90% is available). */
- tp->t_inlow = (ttyinq_getsize(&tp->t_inq) * 9) / 10;
+ tp->t_inlow = (ttyinq_getallocatedsize(&tp->t_inq) * 9) / 10;
/* Provide an ouput buffer for 0.2 seconds of data. */
bs = MIN(tp->t_termios.c_ospeed / 5, TTYBUF_MAX);
ttyoutq_setsize(&tp->t_outq, tp, bs);
/* Set low watermark at 10% (when 90% is available). */
- tp->t_outlow = (ttyoutq_getsize(&tp->t_outq) * 9) / 10;
+ tp->t_outlow = (ttyoutq_getallocatedsize(&tp->t_outq) * 9) / 10;
}
static int
@@ -523,6 +523,34 @@ ttydev_ioctl(struct cdev *dev, u_long cm
goto done;
}
+ if (cmd == TIOCSETA || cmd == TIOCSETAW || cmd == TIOCSETAF) {
+ struct termios *old = &tp->t_termios;
+ struct termios *new = (struct termios *)data;
+ struct termios *lock = TTY_CALLOUT(tp, dev) ?
+ &tp->t_termios_lock_out : &tp->t_termios_lock_in;
+ int cc;
+
+ /*
+ * Lock state devices. Just overwrite the values of the
+ * commands that are currently in use.
+ */
+ new->c_iflag = (old->c_iflag & lock->c_iflag) |
+ (new->c_iflag & ~lock->c_iflag);
+ new->c_oflag = (old->c_oflag & lock->c_oflag) |
+ (new->c_oflag & ~lock->c_oflag);
+ new->c_cflag = (old->c_cflag & lock->c_cflag) |
+ (new->c_cflag & ~lock->c_cflag);
+ new->c_lflag = (old->c_lflag & lock->c_lflag) |
+ (new->c_lflag & ~lock->c_lflag);
+ for (cc = 0; cc < NCCS; ++cc)
+ if (lock->c_cc[cc])
+ new->c_cc[cc] = old->c_cc[cc];
+ if (lock->c_ispeed)
+ new->c_ispeed = old->c_ispeed;
+ if (lock->c_ospeed)
+ new->c_ospeed = old->c_ospeed;
+ }
+
error = tty_ioctl(tp, cmd, data, td);
done: tty_unlock(tp);
Modified: stable/8/sys/sys/ttyqueue.h
==============================================================================
--- stable/8/sys/sys/ttyqueue.h Sun Nov 1 10:01:39 2009 (r198744)
+++ stable/8/sys/sys/ttyqueue.h Sun Nov 1 10:30:30 2009 (r198745)
@@ -93,6 +93,13 @@ ttyinq_getsize(struct ttyinq *ti)
}
static __inline size_t
+ttyinq_getallocatedsize(struct ttyinq *ti)
+{
+
+ return (ti->ti_quota * TTYINQ_DATASIZE);
+}
+
+static __inline size_t
ttyinq_bytesleft(struct ttyinq *ti)
{
size_t len;
@@ -143,6 +150,13 @@ ttyoutq_getsize(struct ttyoutq *to)
}
static __inline size_t
+ttyoutq_getallocatedsize(struct ttyoutq *to)
+{
+
+ return (to->to_quota * TTYOUTQ_DATASIZE);
+}
+
+static __inline size_t
ttyoutq_bytesleft(struct ttyoutq *to)
{
size_t len;
Modified: stable/8/usr.sbin/jail/jail.8
==============================================================================
--- stable/8/usr.sbin/jail/jail.8 Sun Nov 1 10:01:39 2009 (r198744)
+++ stable/8/usr.sbin/jail/jail.8 Sun Nov 1 10:30:30 2009 (r198745)
@@ -34,7 +34,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd July 25, 2009
+.Dd October 18, 2009
.Dt JAIL 8
.Os
.Sh NAME
@@ -377,7 +377,7 @@ Since raw sockets can be used to configu
network subsystems, extra caution should be used where privileged access
to jails is given out to untrusted parties.
.It Va allow.chflags
-Normally, priveleged users inside a jail are treated as unprivileged by
+Normally, privileged users inside a jail are treated as unprivileged by
.Xr chflags 2 .
When this parameter is set, such users are treated as privileged, and
may manipulate system file flags subject to the usual constraints on
From brueffer at FreeBSD.org Sun Nov 1 10:56:04 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Sun Nov 1 10:56:16 2009
Subject: svn commit: r198746 - stable/8/share/man/man4
Message-ID: <200911011056.nA1Au3ic021534@svn.freebsd.org>
Author: brueffer
Date: Sun Nov 1 10:56:03 2009
New Revision: 198746
URL: http://svn.freebsd.org/changeset/base/198746
Log:
MFC: r198609
Revert part of r198363, there is no "device cam", it is
included in "device scbus".
Modified:
stable/8/share/man/man4/ (props changed)
stable/8/share/man/man4/atapicam.4
stable/8/share/man/man4/umass.4
Modified: stable/8/share/man/man4/atapicam.4
==============================================================================
--- stable/8/share/man/man4/atapicam.4 Sun Nov 1 10:30:30 2009 (r198745)
+++ stable/8/share/man/man4/atapicam.4 Sun Nov 1 10:56:03 2009 (r198746)
@@ -39,7 +39,6 @@ place the following lines in your
kernel configuration file:
.Bd -ragged -offset indent
.Cd "device scbus"
-.Cd "device cam"
.Cd "device ata"
.Cd "device atapicam"
.Ed
Modified: stable/8/share/man/man4/umass.4
==============================================================================
--- stable/8/share/man/man4/umass.4 Sun Nov 1 10:30:30 2009 (r198745)
+++ stable/8/share/man/man4/umass.4 Sun Nov 1 10:56:03 2009 (r198746)
@@ -39,7 +39,6 @@ place the following line in your
kernel configuration file:
.Bd -ragged -offset indent
.Cd "device scbus"
-.Cd "device cam"
.Cd "device usb"
.Cd "device umass"
.Ed
From brueffer at FreeBSD.org Sun Nov 1 10:57:07 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Sun Nov 1 10:57:24 2009
Subject: svn commit: r198747 - stable/7/share/man/man4
Message-ID: <200911011057.nA1Av71L021601@svn.freebsd.org>
Author: brueffer
Date: Sun Nov 1 10:57:07 2009
New Revision: 198747
URL: http://svn.freebsd.org/changeset/base/198747
Log:
MFC: r198609
Revert part of r198363, there is no "device cam", it is
included in "device scbus".
Modified:
stable/7/share/man/man4/ (props changed)
stable/7/share/man/man4/atapicam.4
stable/7/share/man/man4/umass.4
Modified: stable/7/share/man/man4/atapicam.4
==============================================================================
--- stable/7/share/man/man4/atapicam.4 Sun Nov 1 10:56:03 2009 (r198746)
+++ stable/7/share/man/man4/atapicam.4 Sun Nov 1 10:57:07 2009 (r198747)
@@ -39,7 +39,6 @@ place the following lines in your
kernel configuration file:
.Bd -ragged -offset indent
.Cd "device scbus"
-.Cd "device cam"
.Cd "device ata"
.Cd "device atapicam"
.Ed
Modified: stable/7/share/man/man4/umass.4
==============================================================================
--- stable/7/share/man/man4/umass.4 Sun Nov 1 10:56:03 2009 (r198746)
+++ stable/7/share/man/man4/umass.4 Sun Nov 1 10:57:07 2009 (r198747)
@@ -39,7 +39,6 @@ place the following line in your
kernel configuration file:
.Bd -ragged -offset indent
.Cd "device scbus"
-.Cd "device cam"
.Cd "device usb"
.Cd "device umass"
.Ed
From mav at FreeBSD.org Sun Nov 1 11:31:07 2009
From: mav at FreeBSD.org (Alexander Motin)
Date: Sun Nov 1 11:31:19 2009
Subject: svn commit: r198748 - in head/sys/cam: . ata scsi
Message-ID: <200911011131.nA1BV6lO022276@svn.freebsd.org>
Author: mav
Date: Sun Nov 1 11:31:06 2009
New Revision: 198748
URL: http://svn.freebsd.org/changeset/base/198748
Log:
MFp4:
Fix reference counting bug, when device unreferenced before then
invalidated. To do it, do not handle validity flag as another
reference, but explicitly modify reference count each time flag is
modified.
Discovered by: thompsa
Modified:
head/sys/cam/ata/ata_xpt.c
head/sys/cam/cam_xpt.c
head/sys/cam/cam_xpt_internal.h
head/sys/cam/scsi/scsi_xpt.c
Modified: head/sys/cam/ata/ata_xpt.c
==============================================================================
--- head/sys/cam/ata/ata_xpt.c Sun Nov 1 10:57:07 2009 (r198747)
+++ head/sys/cam/ata/ata_xpt.c Sun Nov 1 11:31:06 2009 (r198748)
@@ -733,6 +733,7 @@ noerror:
case PROBE_SET_MULTI:
if (periph->path->device->flags & CAM_DEV_UNCONFIGURED) {
path->device->flags &= ~CAM_DEV_UNCONFIGURED;
+ xpt_acquire_device(path->device);
done_ccb->ccb_h.func_code = XPT_GDEV_TYPE;
xpt_action(done_ccb);
xpt_async(AC_FOUND_DEVICE, done_ccb->ccb_h.path,
@@ -777,6 +778,7 @@ noerror:
ata_device_transport(path);
if (periph->path->device->flags & CAM_DEV_UNCONFIGURED) {
path->device->flags &= ~CAM_DEV_UNCONFIGURED;
+ xpt_acquire_device(path->device);
done_ccb->ccb_h.func_code = XPT_GDEV_TYPE;
xpt_action(done_ccb);
xpt_async(AC_FOUND_DEVICE, done_ccb->ccb_h.path, done_ccb);
@@ -810,6 +812,7 @@ noerror:
path->device->flags |= CAM_DEV_IDENTIFY_DATA_VALID;
if (periph->path->device->flags & CAM_DEV_UNCONFIGURED) {
path->device->flags &= ~CAM_DEV_UNCONFIGURED;
+ xpt_acquire_device(path->device);
done_ccb->ccb_h.func_code = XPT_GDEV_TYPE;
xpt_action(done_ccb);
xpt_async(AC_FOUND_DEVICE, done_ccb->ccb_h.path,
@@ -1485,8 +1488,10 @@ ata_dev_async(u_int32_t async_code, stru
CAM_EXPECT_INQ_CHANGE, NULL);
}
xpt_release_path(&newpath);
- } else if (async_code == AC_LOST_DEVICE) {
+ } else if (async_code == AC_LOST_DEVICE &&
+ (device->flags & CAM_DEV_UNCONFIGURED) == 0) {
device->flags |= CAM_DEV_UNCONFIGURED;
+ xpt_release_device(device);
} else if (async_code == AC_TRANSFER_NEG) {
struct ccb_trans_settings *settings;
Modified: head/sys/cam/cam_xpt.c
==============================================================================
--- head/sys/cam/cam_xpt.c Sun Nov 1 10:57:07 2009 (r198747)
+++ head/sys/cam/cam_xpt.c Sun Nov 1 11:31:06 2009 (r198748)
@@ -217,9 +217,7 @@ static void xpt_release_devq_device(str
int run_queue);
static struct cam_et*
xpt_alloc_target(struct cam_eb *bus, target_id_t target_id);
-static void xpt_release_target(struct cam_eb *bus, struct cam_et *target);
-static void xpt_release_device(struct cam_eb *bus, struct cam_et *target,
- struct cam_ed *device);
+static void xpt_release_target(struct cam_et *target);
static struct cam_eb*
xpt_find_bus(path_id_t path_id);
static struct cam_et*
@@ -3521,9 +3519,9 @@ xpt_compile_path(struct cam_path *new_pa
CAM_DEBUG(new_path, CAM_DEBUG_TRACE, ("xpt_compile_path\n"));
} else {
if (device != NULL)
- xpt_release_device(bus, target, device);
+ xpt_release_device(device);
if (target != NULL)
- xpt_release_target(bus, target);
+ xpt_release_target(target);
if (bus != NULL)
xpt_release_bus(bus);
}
@@ -3535,11 +3533,11 @@ xpt_release_path(struct cam_path *path)
{
CAM_DEBUG(path, CAM_DEBUG_TRACE, ("xpt_release_path\n"));
if (path->device != NULL) {
- xpt_release_device(path->bus, path->target, path->device);
+ xpt_release_device(path->device);
path->device = NULL;
}
if (path->target != NULL) {
- xpt_release_target(path->bus, path->target);
+ xpt_release_target(path->target);
path->target = NULL;
}
if (path->bus != NULL) {
@@ -4375,15 +4373,15 @@ xpt_alloc_target(struct cam_eb *bus, tar
}
static void
-xpt_release_target(struct cam_eb *bus, struct cam_et *target)
+xpt_release_target(struct cam_et *target)
{
if ((--target->refcount == 0)
&& (TAILQ_FIRST(&target->ed_entries) == NULL)) {
- TAILQ_REMOVE(&bus->et_entries, target, links);
- bus->generation++;
+ TAILQ_REMOVE(&target->bus->et_entries, target, links);
+ target->bus->generation++;
+ xpt_release_bus(target->bus);
free(target, M_CAMXPT);
- xpt_release_bus(bus);
}
}
@@ -4470,13 +4468,18 @@ xpt_alloc_device(struct cam_eb *bus, str
return (device);
}
-static void
-xpt_release_device(struct cam_eb *bus, struct cam_et *target,
- struct cam_ed *device)
+void
+xpt_acquire_device(struct cam_ed *device)
+{
+
+ device->refcount++;
+}
+
+void
+xpt_release_device(struct cam_ed *device)
{
- if ((--device->refcount == 0)
- && ((device->flags & CAM_DEV_UNCONFIGURED) != 0)) {
+ if (--device->refcount == 0) {
struct cam_devq *devq;
if (device->alloc_ccb_entry.pinfo.index != CAM_UNQUEUED_INDEX
@@ -4486,16 +4489,16 @@ xpt_release_device(struct cam_eb *bus, s
if ((device->flags & CAM_DEV_REL_TIMEOUT_PENDING) != 0)
callout_stop(&device->callout);
- TAILQ_REMOVE(&target->ed_entries, device,links);
- target->generation++;
- bus->sim->max_ccbs -= device->ccbq.devq_openings;
+ TAILQ_REMOVE(&device->target->ed_entries, device,links);
+ device->target->generation++;
+ device->target->bus->sim->max_ccbs -= device->ccbq.devq_openings;
/* Release our slot in the devq */
- devq = bus->sim->devq;
+ devq = device->target->bus->sim->devq;
cam_devq_resize(devq, devq->alloc_queue.array_size - 1);
camq_fini(&device->drvq);
cam_ccbq_fini(&device->ccbq);
+ xpt_release_target(device->target);
free(device, M_CAMXPT);
- xpt_release_target(bus, target);
}
}
Modified: head/sys/cam/cam_xpt_internal.h
==============================================================================
--- head/sys/cam/cam_xpt_internal.h Sun Nov 1 10:57:07 2009 (r198747)
+++ head/sys/cam/cam_xpt_internal.h Sun Nov 1 11:31:06 2009 (r198748)
@@ -37,9 +37,7 @@ struct cam_ed;
typedef struct cam_ed * (*xpt_alloc_device_func)(struct cam_eb *bus,
struct cam_et *target,
lun_id_t lun_id);
-typedef void (*xpt_release_device_func)(struct cam_eb *bus,
- struct cam_et *target,
- struct cam_ed *device);
+typedef void (*xpt_release_device_func)(struct cam_ed *device);
typedef void (*xpt_action_func)(union ccb *start_ccb);
typedef void (*xpt_dev_async_func)(u_int32_t async_code,
struct cam_eb *bus,
@@ -172,6 +170,8 @@ struct xpt_xport * ata_get_xport(void);
struct cam_ed * xpt_alloc_device(struct cam_eb *bus,
struct cam_et *target,
lun_id_t lun_id);
+void xpt_acquire_device(struct cam_ed *device);
+void xpt_release_device(struct cam_ed *device);
void xpt_run_dev_sendq(struct cam_eb *bus);
int xpt_schedule_dev(struct camq *queue, cam_pinfo *dev_pinfo,
u_int32_t new_priority);
Modified: head/sys/cam/scsi/scsi_xpt.c
==============================================================================
--- head/sys/cam/scsi/scsi_xpt.c Sun Nov 1 10:57:07 2009 (r198747)
+++ head/sys/cam/scsi/scsi_xpt.c Sun Nov 1 11:31:06 2009 (r198748)
@@ -1076,8 +1076,10 @@ probedone(struct cam_periph *periph, uni
else
PROBE_SET_ACTION(softc, PROBE_SERIAL_NUM_0);
- path->device->flags &= ~CAM_DEV_UNCONFIGURED;
-
+ if (path->device->flags & CAM_DEV_UNCONFIGURED) {
+ path->device->flags &= ~CAM_DEV_UNCONFIGURED;
+ xpt_acquire_device(path->device);
+ }
xpt_release_ccb(done_ccb);
xpt_schedule(periph, priority);
return;
@@ -1336,8 +1338,12 @@ probedone(struct cam_periph *periph, uni
CAM_DEBUG(periph->path, CAM_DEBUG_INFO,
("Leave Domain Validation\n"));
}
+ if (path->device->flags & CAM_DEV_UNCONFIGURED) {
+ path->device->flags &= ~CAM_DEV_UNCONFIGURED;
+ xpt_acquire_device(path->device);
+ }
path->device->flags &=
- ~(CAM_DEV_UNCONFIGURED|CAM_DEV_IN_DV|CAM_DEV_DV_HIT_BOTTOM);
+ ~(CAM_DEV_IN_DV|CAM_DEV_DV_HIT_BOTTOM);
if ((softc->flags & PROBE_NO_ANNOUNCE) == 0) {
/* Inform the XPT that a new device has been found */
done_ccb->ccb_h.func_code = XPT_GDEV_TYPE;
@@ -1387,8 +1393,12 @@ probedone(struct cam_periph *periph, uni
CAM_DEBUG(periph->path, CAM_DEBUG_INFO,
("Leave Domain Validation Successfully\n"));
}
+ if (path->device->flags & CAM_DEV_UNCONFIGURED) {
+ path->device->flags &= ~CAM_DEV_UNCONFIGURED;
+ xpt_acquire_device(path->device);
+ }
path->device->flags &=
- ~(CAM_DEV_UNCONFIGURED|CAM_DEV_IN_DV|CAM_DEV_DV_HIT_BOTTOM);
+ ~(CAM_DEV_IN_DV|CAM_DEV_DV_HIT_BOTTOM);
if ((softc->flags & PROBE_NO_ANNOUNCE) == 0) {
/* Inform the XPT that a new device has been found */
done_ccb->ccb_h.func_code = XPT_GDEV_TYPE;
@@ -2375,8 +2385,10 @@ scsi_dev_async(u_int32_t async_code, str
CAM_EXPECT_INQ_CHANGE, NULL);
}
xpt_release_path(&newpath);
- } else if (async_code == AC_LOST_DEVICE) {
+ } else if (async_code == AC_LOST_DEVICE &&
+ (device->flags & CAM_DEV_UNCONFIGURED) == 0) {
device->flags |= CAM_DEV_UNCONFIGURED;
+ xpt_release_device(device);
} else if (async_code == AC_TRANSFER_NEG) {
struct ccb_trans_settings *settings;
From avg at FreeBSD.org Sun Nov 1 11:34:14 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 11:34:22 2009
Subject: svn commit: r198749 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/xen/xenpci pci
Message-ID: <200911011134.nA1BYD9f022372@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 11:34:13 2009
New Revision: 198749
URL: http://svn.freebsd.org/changeset/base/198749
Log:
MFC r197128,197325: add support for smbus controller found in AMD SB700
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
stable/8/sys/pci/intpm.c
stable/8/sys/pci/intpmreg.h
Modified: stable/8/sys/pci/intpm.c
==============================================================================
--- stable/8/sys/pci/intpm.c Sun Nov 1 11:31:06 2009 (r198748)
+++ stable/8/sys/pci/intpm.c Sun Nov 1 11:34:13 2009 (r198749)
@@ -53,6 +53,8 @@ struct intsmb_softc {
void *irq_hand;
device_t smbus;
int isbusy;
+ int cfg_irq9;
+ int poll;
struct mtx lock;
};
@@ -96,6 +98,10 @@ intsmb_probe(device_t dev)
#endif
device_set_desc(dev, "Intel PIIX4 SMBUS Interface");
break;
+ case 0x43851002:
+ device_set_desc(dev, "AMD SB600/700/710/750 SMBus Controller");
+ /* XXX Maybe force polling right here? */
+ break;
default:
return (ENXIO);
}
@@ -108,12 +114,24 @@ intsmb_attach(device_t dev)
{
struct intsmb_softc *sc = device_get_softc(dev);
int error, rid, value;
+ int intr;
char *str;
sc->dev = dev;
mtx_init(&sc->lock, device_get_nameunit(dev), "intsmb", MTX_DEF);
+ sc->cfg_irq9 = 0;
+#ifndef NO_CHANGE_PCICONF
+ switch (pci_get_devid(dev)) {
+ case 0x71138086: /* Intel 82371AB */
+ case 0x719b8086: /* Intel 82443MX */
+ /* Changing configuration is allowed. */
+ sc->cfg_irq9 = 1;
+ break;
+ }
+#endif
+
rid = PCI_BASE_ADDR_SMB;
sc->io_res = bus_alloc_resource_any(dev, SYS_RES_IOPORT, &rid,
RF_ACTIVE);
@@ -123,27 +141,42 @@ intsmb_attach(device_t dev)
goto fail;
}
-#ifndef NO_CHANGE_PCICONF
- pci_write_config(dev, PCIR_INTLINE, 0x9, 1);
- pci_write_config(dev, PCI_HST_CFG_SMB,
- PCI_INTR_SMB_IRQ9 | PCI_INTR_SMB_ENABLE, 1);
-#endif
+ if (sc->cfg_irq9) {
+ pci_write_config(dev, PCIR_INTLINE, 0x9, 1);
+ pci_write_config(dev, PCI_HST_CFG_SMB,
+ PCI_INTR_SMB_IRQ9 | PCI_INTR_SMB_ENABLE, 1);
+ }
value = pci_read_config(dev, PCI_HST_CFG_SMB, 1);
- switch (value & 0xe) {
+ sc->poll = (value & PCI_INTR_SMB_ENABLE) == 0;
+ intr = value & PCI_INTR_SMB_MASK;
+ switch (intr) {
case PCI_INTR_SMB_SMI:
str = "SMI";
break;
case PCI_INTR_SMB_IRQ9:
str = "IRQ 9";
break;
+ case PCI_INTR_SMB_IRQ_PCI:
+ str = "PCI IRQ";
+ break;
default:
str = "BOGUS";
}
+
device_printf(dev, "intr %s %s ", str,
- (value & 1) ? "enabled" : "disabled");
+ sc->poll == 0 ? "enabled" : "disabled");
printf("revision %d\n", pci_read_config(dev, PCI_REVID_SMB, 1));
- if ((value & 0xe) != PCI_INTR_SMB_IRQ9) {
+ if (!sc->poll && intr == PCI_INTR_SMB_SMI) {
+ device_printf(dev,
+ "using polling mode when configured interrupt is SMI\n");
+ sc->poll = 1;
+ }
+
+ if (sc->poll)
+ goto no_intr;
+
+ if (intr != PCI_INTR_SMB_IRQ9 && intr != PCI_INTR_SMB_IRQ_PCI) {
device_printf(dev, "Unsupported interrupt mode\n");
error = ENXIO;
goto fail;
@@ -151,7 +184,9 @@ intsmb_attach(device_t dev)
/* Force IRQ 9. */
rid = 0;
- bus_set_resource(dev, SYS_RES_IRQ, rid, 9, 1);
+ if (sc->cfg_irq9)
+ bus_set_resource(dev, SYS_RES_IRQ, rid, 9, 1);
+
sc->irq_res = bus_alloc_resource_any(dev, SYS_RES_IRQ, &rid,
RF_SHAREABLE | RF_ACTIVE);
if (sc->irq_res == NULL) {
@@ -167,6 +202,7 @@ intsmb_attach(device_t dev)
goto fail;
}
+no_intr:
sc->isbusy = 0;
sc->smbus = device_add_child(dev, "smbus", -1);
if (sc->smbus == NULL) {
@@ -361,7 +397,7 @@ intsmb_start(struct intsmb_softc *sc, un
tmp |= PIIX4_SMBHSTCNT_START;
/* While not in autoconfiguration enable interrupts. */
- if (!cold && !nointr)
+ if (!sc->poll && !cold && !nointr)
tmp |= PIIX4_SMBHSTCNT_INTREN;
bus_write_1(sc->io_res, PIIX4_SMBHSTCNT, tmp);
}
@@ -411,8 +447,6 @@ intsmb_stop_poll(struct intsmb_softc *sc
if (!(status & PIIX4_SMBHSTSTAT_BUSY)) {
sc->isbusy = 0;
error = intsmb_error(sc->dev, status);
- if (error == 0 && !(status & PIIX4_SMBHSTSTAT_INTR))
- device_printf(sc->dev, "unknown cause why?\n");
return (error);
}
}
@@ -434,7 +468,7 @@ intsmb_stop(struct intsmb_softc *sc)
INTSMB_LOCK_ASSERT(sc);
- if (cold)
+ if (sc->poll || cold)
/* So that it can use device during device probe on SMBus. */
return (intsmb_stop_poll(sc));
Modified: stable/8/sys/pci/intpmreg.h
==============================================================================
--- stable/8/sys/pci/intpmreg.h Sun Nov 1 11:31:06 2009 (r198748)
+++ stable/8/sys/pci/intpmreg.h Sun Nov 1 11:34:13 2009 (r198749)
@@ -35,7 +35,9 @@
#define PCI_BASE_ADDR_SMB 0x90 /* IO BAR. */
#define PCI_BASE_ADDR_PM 0x40
#define PCI_HST_CFG_SMB 0xd2 /* Host Configuration */
+#define PCI_INTR_SMB_MASK 0xe
#define PCI_INTR_SMB_SMI 0
+#define PCI_INTR_SMB_IRQ_PCI 2
#define PCI_INTR_SMB_IRQ9 8
#define PCI_INTR_SMB_ENABLE 1
#define PCI_SLV_CMD_SMB 0xd3 /*SLAVE COMMAND*/
From brueffer at FreeBSD.org Sun Nov 1 11:39:08 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Sun Nov 1 11:39:19 2009
Subject: svn commit: r198750 - head/usr.sbin/usbconfig
Message-ID: <200911011139.nA1Bd8nf022525@svn.freebsd.org>
Author: brueffer
Date: Sun Nov 1 11:39:07 2009
New Revision: 198750
URL: http://svn.freebsd.org/changeset/base/198750
Log:
Expand DESCRIPTION and a basic EXAMPLES section.
PR: 139605
Submitted by: Warren Block
MFC after: 1 week
Modified:
head/usr.sbin/usbconfig/usbconfig.8
Modified: head/usr.sbin/usbconfig/usbconfig.8
==============================================================================
--- head/usr.sbin/usbconfig/usbconfig.8 Sun Nov 1 11:34:13 2009 (r198749)
+++ head/usr.sbin/usbconfig/usbconfig.8 Sun Nov 1 11:39:07 2009 (r198750)
@@ -23,7 +23,7 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.Dd Sep 28, 2008
+.Dd November 1, 2009
.Dt USBCONFIG 8
.Os
.Sh NAME
@@ -49,5 +49,13 @@ Should only be used in conjunction with
.It Fl h
Show help and available commands.
.El
+.Pp
+When called without options,
+.Nm
+prints a list of all available USB devices.
+.Sh EXAMPLES
+Show information about the device on USB bus 1 at address 2:
+.Pp
+.Dl usbconfig -u 1 -a 2 dump_info
.Sh SEE ALSO
.Xr usb 4
From avg at FreeBSD.org Sun Nov 1 11:41:20 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 11:41:26 2009
Subject: svn commit: r198751 - in stable/7/sys: . contrib/pf pci
Message-ID: <200911011141.nA1BfKcP022599@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 11:41:20 2009
New Revision: 198751
URL: http://svn.freebsd.org/changeset/base/198751
Log:
MFC r197128,197325: add support for smbus controller found in AMD SB700
Modified:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/pci/intpm.c
stable/7/sys/pci/intpmreg.h
Modified: stable/7/sys/pci/intpm.c
==============================================================================
--- stable/7/sys/pci/intpm.c Sun Nov 1 11:39:07 2009 (r198750)
+++ stable/7/sys/pci/intpm.c Sun Nov 1 11:41:20 2009 (r198751)
@@ -53,6 +53,8 @@ struct intsmb_softc {
void *irq_hand;
device_t smbus;
int isbusy;
+ int cfg_irq9;
+ int poll;
struct mtx lock;
};
@@ -96,6 +98,10 @@ intsmb_probe(device_t dev)
#endif
device_set_desc(dev, "Intel PIIX4 SMBUS Interface");
break;
+ case 0x43851002:
+ device_set_desc(dev, "AMD SB600/700/710/750 SMBus Controller");
+ /* XXX Maybe force polling right here? */
+ break;
default:
return (ENXIO);
}
@@ -108,12 +114,24 @@ intsmb_attach(device_t dev)
{
struct intsmb_softc *sc = device_get_softc(dev);
int error, rid, value;
+ int intr;
char *str;
sc->dev = dev;
mtx_init(&sc->lock, device_get_nameunit(dev), "intsmb", MTX_DEF);
+ sc->cfg_irq9 = 0;
+#ifndef NO_CHANGE_PCICONF
+ switch (pci_get_devid(dev)) {
+ case 0x71138086: /* Intel 82371AB */
+ case 0x719b8086: /* Intel 82443MX */
+ /* Changing configuration is allowed. */
+ sc->cfg_irq9 = 1;
+ break;
+ }
+#endif
+
rid = PCI_BASE_ADDR_SMB;
sc->io_res = bus_alloc_resource_any(dev, SYS_RES_IOPORT, &rid,
RF_ACTIVE);
@@ -123,27 +141,42 @@ intsmb_attach(device_t dev)
goto fail;
}
-#ifndef NO_CHANGE_PCICONF
- pci_write_config(dev, PCIR_INTLINE, 0x9, 1);
- pci_write_config(dev, PCI_HST_CFG_SMB,
- PCI_INTR_SMB_IRQ9 | PCI_INTR_SMB_ENABLE, 1);
-#endif
+ if (sc->cfg_irq9) {
+ pci_write_config(dev, PCIR_INTLINE, 0x9, 1);
+ pci_write_config(dev, PCI_HST_CFG_SMB,
+ PCI_INTR_SMB_IRQ9 | PCI_INTR_SMB_ENABLE, 1);
+ }
value = pci_read_config(dev, PCI_HST_CFG_SMB, 1);
- switch (value & 0xe) {
+ sc->poll = (value & PCI_INTR_SMB_ENABLE) == 0;
+ intr = value & PCI_INTR_SMB_MASK;
+ switch (intr) {
case PCI_INTR_SMB_SMI:
str = "SMI";
break;
case PCI_INTR_SMB_IRQ9:
str = "IRQ 9";
break;
+ case PCI_INTR_SMB_IRQ_PCI:
+ str = "PCI IRQ";
+ break;
default:
str = "BOGUS";
}
+
device_printf(dev, "intr %s %s ", str,
- (value & 1) ? "enabled" : "disabled");
+ sc->poll == 0 ? "enabled" : "disabled");
printf("revision %d\n", pci_read_config(dev, PCI_REVID_SMB, 1));
- if ((value & 0xe) != PCI_INTR_SMB_IRQ9) {
+ if (!sc->poll && intr == PCI_INTR_SMB_SMI) {
+ device_printf(dev,
+ "using polling mode when configured interrupt is SMI\n");
+ sc->poll = 1;
+ }
+
+ if (sc->poll)
+ goto no_intr;
+
+ if (intr != PCI_INTR_SMB_IRQ9 && intr != PCI_INTR_SMB_IRQ_PCI) {
device_printf(dev, "Unsupported interrupt mode\n");
error = ENXIO;
goto fail;
@@ -151,7 +184,9 @@ intsmb_attach(device_t dev)
/* Force IRQ 9. */
rid = 0;
- bus_set_resource(dev, SYS_RES_IRQ, rid, 9, 1);
+ if (sc->cfg_irq9)
+ bus_set_resource(dev, SYS_RES_IRQ, rid, 9, 1);
+
sc->irq_res = bus_alloc_resource_any(dev, SYS_RES_IRQ, &rid,
RF_SHAREABLE | RF_ACTIVE);
if (sc->irq_res == NULL) {
@@ -167,6 +202,7 @@ intsmb_attach(device_t dev)
goto fail;
}
+no_intr:
sc->isbusy = 0;
sc->smbus = device_add_child(dev, "smbus", -1);
if (sc->smbus == NULL) {
@@ -361,7 +397,7 @@ intsmb_start(struct intsmb_softc *sc, un
tmp |= PIIX4_SMBHSTCNT_START;
/* While not in autoconfiguration enable interrupts. */
- if (!cold && !nointr)
+ if (!sc->poll && !cold && !nointr)
tmp |= PIIX4_SMBHSTCNT_INTREN;
bus_write_1(sc->io_res, PIIX4_SMBHSTCNT, tmp);
}
@@ -411,8 +447,6 @@ intsmb_stop_poll(struct intsmb_softc *sc
if (!(status & PIIX4_SMBHSTSTAT_BUSY)) {
sc->isbusy = 0;
error = intsmb_error(sc->dev, status);
- if (error == 0 && !(status & PIIX4_SMBHSTSTAT_INTR))
- device_printf(sc->dev, "unknown cause why?\n");
return (error);
}
}
@@ -434,7 +468,7 @@ intsmb_stop(struct intsmb_softc *sc)
INTSMB_LOCK_ASSERT(sc);
- if (cold)
+ if (sc->poll || cold)
/* So that it can use device during device probe on SMBus. */
return (intsmb_stop_poll(sc));
Modified: stable/7/sys/pci/intpmreg.h
==============================================================================
--- stable/7/sys/pci/intpmreg.h Sun Nov 1 11:39:07 2009 (r198750)
+++ stable/7/sys/pci/intpmreg.h Sun Nov 1 11:41:20 2009 (r198751)
@@ -35,7 +35,9 @@
#define PCI_BASE_ADDR_SMB 0x90 /* IO BAR. */
#define PCI_BASE_ADDR_PM 0x40
#define PCI_HST_CFG_SMB 0xd2 /* Host Configuration */
+#define PCI_INTR_SMB_MASK 0xe
#define PCI_INTR_SMB_SMI 0
+#define PCI_INTR_SMB_IRQ_PCI 2
#define PCI_INTR_SMB_IRQ9 8
#define PCI_INTR_SMB_ENABLE 1
#define PCI_SLV_CMD_SMB 0xd3 /*SLAVE COMMAND*/
From mav at FreeBSD.org Sun Nov 1 13:06:15 2009
From: mav at FreeBSD.org (Alexander Motin)
Date: Sun Nov 1 13:06:22 2009
Subject: svn commit: r198752 - head/sys/dev/ata/chipsets
Message-ID: <200911011306.nA1D6F4x024211@svn.freebsd.org>
Author: mav
Date: Sun Nov 1 13:06:15 2009
New Revision: 198752
URL: http://svn.freebsd.org/changeset/base/198752
Log:
MFp4:
Allow SATA1 SiI chips to do full-sized DMA. Specification tells that we may
release DMA constrants even more, but it require some additional handling.
Modified:
head/sys/dev/ata/chipsets/ata-siliconimage.c
Modified: head/sys/dev/ata/chipsets/ata-siliconimage.c
==============================================================================
--- head/sys/dev/ata/chipsets/ata-siliconimage.c Sun Nov 1 11:41:20 2009 (r198751)
+++ head/sys/dev/ata/chipsets/ata-siliconimage.c Sun Nov 1 13:06:15 2009 (r198752)
@@ -340,6 +340,7 @@ ata_sii_ch_attach(device_t dev)
ATA_OUTL(ctlr->r_res2, 0x148 + (unit01 << 7) + (unit10 << 8),(1 << 16));
}
+ ch->dma.max_iosize = (ATA_DMA_ENTRIES - 1) * PAGE_SIZE;
if (ctlr->chip->cfg2 & SII_BUG) {
/* work around errata in early chips */
ch->dma.boundary = 8192;
From rwatson at FreeBSD.org Sun Nov 1 15:15:45 2009
From: rwatson at FreeBSD.org (Robert Watson)
Date: Sun Nov 1 15:15:51 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To: <200910311035.n9VAZfIb082932@svn.freebsd.org>
References: <200910311035.n9VAZfIb082932@svn.freebsd.org>
Message-ID:
On Sat, 31 Oct 2009, Ed Schouten wrote:
> Turn unused structure fields of cdevsw into spares.
>
> d_uid, d_gid and d_mode are unused, because permissions are stored in
> cdevpriv nowadays. d_kind doesn't seem to be used at all. We no longer
> keep a list of cdevsw's, so d_list is also unused.
>
> uid_t and gid_t are 32 bits, but mode_t is 16 bits, Because of alignment
> constraints of d_kind, we can safely turn it into three 32-bit integers.
> d_kind and d_list is equal in size to three pointers.
The underlying change seems fine, especially in -CURRENT, but I'm confused by
the paragraph here on alignment and safety. What do you mean by safe, and
does it matter? From a casual glance (perhaps mistaken), it looks like this
changes the KBI, so all modules declaring struct cdevsw will need to be
rebuilt.
Robert N M Watson
Computer Laboratory
University of Cambridge
>
> Discussed with: kib
>
> Modified:
> head/sys/sys/conf.h
>
> Modified: head/sys/sys/conf.h
> ==============================================================================
> --- head/sys/sys/conf.h Sat Oct 31 09:03:48 2009 (r198705)
> +++ head/sys/sys/conf.h Sat Oct 31 10:35:41 2009 (r198706)
> @@ -210,15 +210,13 @@ struct cdevsw {
> d_kqfilter_t *d_kqfilter;
> d_purge_t *d_purge;
> d_mmap_single_t *d_mmap_single;
> - uid_t d_uid;
> - gid_t d_gid;
> - mode_t d_mode;
> - const char *d_kind;
> +
> + int32_t d_spare0[3];
> + void *d_spare1[3];
>
> /* These fields should not be messed with by drivers */
> - LIST_ENTRY(cdevsw) d_list;
> LIST_HEAD(, cdev) d_devs;
> - int d_spare3;
> + int d_spare2;
> union {
> struct cdevsw *gianttrick;
> SLIST_ENTRY(cdevsw) postfree_list;
>
From rwatson at FreeBSD.org Sun Nov 1 15:31:29 2009
From: rwatson at FreeBSD.org (Robert Watson)
Date: Sun Nov 1 15:31:42 2009
Subject: svn commit: r198745 - in stable/8: etc sys sys/amd64/include/xen
sys/cddl/contrib/opensolaris sys/contrib/dev/acpica sys/contrib/pf
sys/dev/syscons sys/dev/xen/xenpci sys/kern sys/sys usr.sbin/jail
In-Reply-To: <200911011030.nA1AUVsN019962@svn.freebsd.org>
References: <200911011030.nA1AUVsN019962@svn.freebsd.org>
Message-ID:
On Sun, 1 Nov 2009, Ed Schouten wrote:
> Log:
> MFC various commits back to stable/8:
Is there some relationship between the various changesets merged together
here? One nice thing about grouping merged changesets in some way is that it
makes backing them out more sensible if there's a problem (since you just
revert the whole changeset, etc).
Robert
>
> SVN r197174:
> Make sure we never place the cursor outside the screen.
>
> For some vague reason, it may be possible that scp->cursor_pos exceeds
> scp->ysize * scp->xsize. This means that teken_set_cursor() may get
> called with an invalid position. Just ignore the old cursor position in
> this case.
>
> Reported by: Paul B. Mahol
>
> SVN r198213:
> Make lock devices work properly.
>
> It turned out I did add the code to use the init state devices to set
> the termios structure when opening the device, but it seems I totally
> forgot to add the bits required to force the actual locking of flags
> through the lock state devices.
>
> Reported by: ru
>
> SVN r198215, r198217:
> Fix a typo in the jail(8) manpage.
>
> Submitted by: Jille Timmermans
>
> SVN r198216:
> Fix qouting in a comment, to make it look more consistent
>
> Submitted by: Jille Timmermans
>
> SVN r198223:
> Properly set the low watermarks when reducing the baud rate.
>
> Now that buffers are deallocated lazily, we should not use
> tty*q_getsize() to obtain the buffer size to calculate the low
> watermarks. Doing this may cause the watermark to be placed outside the
> typical buffer size.
>
> This caused some regressions after my previous commit to the TTY code,
> which allows pseudo-devices to resize the buffers as well.
>
> Reported by: yongari, dougb
>
> Modified:
> stable/8/etc/ (props changed)
> stable/8/etc/rc.subr
> stable/8/sys/ (props changed)
> stable/8/sys/amd64/include/xen/ (props changed)
> stable/8/sys/cddl/contrib/opensolaris/ (props changed)
> stable/8/sys/contrib/dev/acpica/ (props changed)
> stable/8/sys/contrib/pf/ (props changed)
> stable/8/sys/dev/syscons/scterm-teken.c
> stable/8/sys/dev/xen/xenpci/ (props changed)
> stable/8/sys/kern/tty.c
> stable/8/sys/sys/ttyqueue.h
> stable/8/usr.sbin/jail/ (props changed)
> stable/8/usr.sbin/jail/jail.8
>
> Modified: stable/8/etc/rc.subr
> ==============================================================================
> --- stable/8/etc/rc.subr Sun Nov 1 10:01:39 2009 (r198744)
> +++ stable/8/etc/rc.subr Sun Nov 1 10:30:30 2009 (r198745)
> @@ -565,7 +565,7 @@ run_rc_command()
> rc_fast=yes
> rc_quiet=yes
> ;;
> - force*) # "force prefix; always run
> + force*) # "force" prefix; always run
> rc_force=yes
> _rc_prefix=force
> rc_arg=${rc_arg#${_rc_prefix}}
>
> Modified: stable/8/sys/dev/syscons/scterm-teken.c
> ==============================================================================
> --- stable/8/sys/dev/syscons/scterm-teken.c Sun Nov 1 10:01:39 2009 (r198744)
> +++ stable/8/sys/dev/syscons/scterm-teken.c Sun Nov 1 10:30:30 2009 (r198745)
> @@ -130,9 +130,12 @@ scteken_init(scr_stat *scp, void **softc
> tp.tp_col = scp->xsize;
> teken_set_winsize(&ts->ts_teken, &tp);
>
> - tp.tp_row = scp->cursor_pos / scp->xsize;
> - tp.tp_col = scp->cursor_pos % scp->xsize;
> - teken_set_cursor(&ts->ts_teken, &tp);
> + if (scp->cursor_pos < scp->ysize * scp->xsize) {
> + /* Valid old cursor position. */
> + tp.tp_row = scp->cursor_pos / scp->xsize;
> + tp.tp_col = scp->cursor_pos % scp->xsize;
> + teken_set_cursor(&ts->ts_teken, &tp);
> + }
> break;
> }
>
>
> Modified: stable/8/sys/kern/tty.c
> ==============================================================================
> --- stable/8/sys/kern/tty.c Sun Nov 1 10:01:39 2009 (r198744)
> +++ stable/8/sys/kern/tty.c Sun Nov 1 10:30:30 2009 (r198745)
> @@ -109,14 +109,14 @@ tty_watermarks(struct tty *tp)
> ttyinq_setsize(&tp->t_inq, tp, bs);
>
> /* Set low watermark at 10% (when 90% is available). */
> - tp->t_inlow = (ttyinq_getsize(&tp->t_inq) * 9) / 10;
> + tp->t_inlow = (ttyinq_getallocatedsize(&tp->t_inq) * 9) / 10;
>
> /* Provide an ouput buffer for 0.2 seconds of data. */
> bs = MIN(tp->t_termios.c_ospeed / 5, TTYBUF_MAX);
> ttyoutq_setsize(&tp->t_outq, tp, bs);
>
> /* Set low watermark at 10% (when 90% is available). */
> - tp->t_outlow = (ttyoutq_getsize(&tp->t_outq) * 9) / 10;
> + tp->t_outlow = (ttyoutq_getallocatedsize(&tp->t_outq) * 9) / 10;
> }
>
> static int
> @@ -523,6 +523,34 @@ ttydev_ioctl(struct cdev *dev, u_long cm
> goto done;
> }
>
> + if (cmd == TIOCSETA || cmd == TIOCSETAW || cmd == TIOCSETAF) {
> + struct termios *old = &tp->t_termios;
> + struct termios *new = (struct termios *)data;
> + struct termios *lock = TTY_CALLOUT(tp, dev) ?
> + &tp->t_termios_lock_out : &tp->t_termios_lock_in;
> + int cc;
> +
> + /*
> + * Lock state devices. Just overwrite the values of the
> + * commands that are currently in use.
> + */
> + new->c_iflag = (old->c_iflag & lock->c_iflag) |
> + (new->c_iflag & ~lock->c_iflag);
> + new->c_oflag = (old->c_oflag & lock->c_oflag) |
> + (new->c_oflag & ~lock->c_oflag);
> + new->c_cflag = (old->c_cflag & lock->c_cflag) |
> + (new->c_cflag & ~lock->c_cflag);
> + new->c_lflag = (old->c_lflag & lock->c_lflag) |
> + (new->c_lflag & ~lock->c_lflag);
> + for (cc = 0; cc < NCCS; ++cc)
> + if (lock->c_cc[cc])
> + new->c_cc[cc] = old->c_cc[cc];
> + if (lock->c_ispeed)
> + new->c_ispeed = old->c_ispeed;
> + if (lock->c_ospeed)
> + new->c_ospeed = old->c_ospeed;
> + }
> +
> error = tty_ioctl(tp, cmd, data, td);
> done: tty_unlock(tp);
>
>
> Modified: stable/8/sys/sys/ttyqueue.h
> ==============================================================================
> --- stable/8/sys/sys/ttyqueue.h Sun Nov 1 10:01:39 2009 (r198744)
> +++ stable/8/sys/sys/ttyqueue.h Sun Nov 1 10:30:30 2009 (r198745)
> @@ -93,6 +93,13 @@ ttyinq_getsize(struct ttyinq *ti)
> }
>
> static __inline size_t
> +ttyinq_getallocatedsize(struct ttyinq *ti)
> +{
> +
> + return (ti->ti_quota * TTYINQ_DATASIZE);
> +}
> +
> +static __inline size_t
> ttyinq_bytesleft(struct ttyinq *ti)
> {
> size_t len;
> @@ -143,6 +150,13 @@ ttyoutq_getsize(struct ttyoutq *to)
> }
>
> static __inline size_t
> +ttyoutq_getallocatedsize(struct ttyoutq *to)
> +{
> +
> + return (to->to_quota * TTYOUTQ_DATASIZE);
> +}
> +
> +static __inline size_t
> ttyoutq_bytesleft(struct ttyoutq *to)
> {
> size_t len;
>
> Modified: stable/8/usr.sbin/jail/jail.8
> ==============================================================================
> --- stable/8/usr.sbin/jail/jail.8 Sun Nov 1 10:01:39 2009 (r198744)
> +++ stable/8/usr.sbin/jail/jail.8 Sun Nov 1 10:30:30 2009 (r198745)
> @@ -34,7 +34,7 @@
> .\"
> .\" $FreeBSD$
> .\"
> -.Dd July 25, 2009
> +.Dd October 18, 2009
> .Dt JAIL 8
> .Os
> .Sh NAME
> @@ -377,7 +377,7 @@ Since raw sockets can be used to configu
> network subsystems, extra caution should be used where privileged access
> to jails is given out to untrusted parties.
> .It Va allow.chflags
> -Normally, priveleged users inside a jail are treated as unprivileged by
> +Normally, privileged users inside a jail are treated as unprivileged by
> .Xr chflags 2 .
> When this parameter is set, such users are treated as privileged, and
> may manipulate system file flags subject to the usual constraints on
>
From ed at 80386.nl Sun Nov 1 15:33:41 2009
From: ed at 80386.nl (Ed Schouten)
Date: Sun Nov 1 15:33:53 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To:
References: <200910311035.n9VAZfIb082932@svn.freebsd.org>
Message-ID: <20091101153339.GH1293@hoeg.nl>
Hi Robert,
* Robert Watson wrote:
> The underlying change seems fine, especially in -CURRENT, but I'm
> confused by the paragraph here on alignment and safety. What do you
> mean by safe, and does it matter?
With safe I mean that all useful members still begin at the same offset
within the structure. I'm not sure whether it matters at all, because I
can imagine d_devs could be moved around without having any effect, but
I'm not going to make any predictions on that.
> From a casual glance (perhaps mistaken), it looks like this changes
> the KBI, so all modules declaring struct cdevsw will need to be
> rebuilt.
It shouldn't, right?
- uid_t d_uid;
- gid_t d_gid;
- mode_t d_mode;
- const char *d_kind;
+
+ int32_t d_spare0[3];
+ void *d_spare1[3];
/* These fields should not be messed with by drivers */
- LIST_ENTRY(cdevsw) d_list;
d_uid, d_gid and d_mode is equal to:
int32_t d_uid;
int32_t d_gid;
int16_t d_mode;
Because d_kind is a pointer, there will be a hole in the structure of at
least 2 bytes (maybe even 6), which means we can safely extend d_mode to
32 bits as well. I could have decided to leave it at uint16_t, but that
would only obfuscate it even more when we would try to reclaim some
space there.
d_list is just two pointers, so I merged it with d_kind into an array of
three pointers.
--
Ed Schouten
WWW: http://80386.nl/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091101/e1ea844e/attachment.pgp
From ed at 80386.nl Sun Nov 1 15:43:37 2009
From: ed at 80386.nl (Ed Schouten)
Date: Sun Nov 1 15:43:43 2009
Subject: svn commit: r198745 - in stable/8: etc sys
sys/amd64/include/xen sys/cddl/contrib/opensolaris sys/contrib/dev/acpica
sys/contrib/pf sys/dev/syscons sys/dev/xen/xenpci sys/kern sys/sys
usr.sbin/jail
In-Reply-To:
References: <200911011030.nA1AUVsN019962@svn.freebsd.org>
Message-ID: <20091101154335.GJ1293@hoeg.nl>
Hello Robert,
* Robert Watson wrote:
> Is there some relationship between the various changesets merged
> together here? One nice thing about grouping merged changesets in
> some way is that it makes backing them out more sensible if there's
> a problem (since you just revert the whole changeset, etc).
Well, it initially happened like this, because I wanted to merge back
multiple changes back to releng/8 with re@'s approval. re@ required diff
files to include commit messages and proper mergeinfo.
Because I can't think of a way to prepare a larger set of patches that
include proper mergeinfo without constantly reverting back and forth or
keeping track of multiple 1.2 GB checkouts, I eventually just decided to
create a bigger patch, so it was more an exception than a routine.
Reverting patches shouldn't be a problem, because I could always just
svn merge -c -123456 to revert individual commits.
--
Ed Schouten
WWW: http://80386.nl/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091101/e48ad2ac/attachment.pgp
From rwatson at FreeBSD.org Sun Nov 1 16:15:22 2009
From: rwatson at FreeBSD.org (Robert N. M. Watson)
Date: Sun Nov 1 16:15:32 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To: <20091101153339.GH1293@hoeg.nl>
References: <200910311035.n9VAZfIb082932@svn.freebsd.org>
<20091101153339.GH1293@hoeg.nl>
Message-ID:
On 1 Nov 2009, at 15:33, Ed Schouten wrote:
> Because d_kind is a pointer, there will be a hole in the structure
> of at
> least 2 bytes (maybe even 6), which means we can safely extend
> d_mode to
> 32 bits as well. I could have decided to leave it at uint16_t, but
> that
> would only obfuscate it even more when we would try to reclaim some
> space there.
>
> d_list is just two pointers, so I merged it with d_kind into an
> array of
> three pointers
No, you're right, and I was mistaken, it seems fine on i386 and amd64.
And, at least here, d_devs is at the same offset on both
architectures. The only really "weird" architecture is arm, which I
believe aligns char and short to 32-bit, but that should be OK here I
think as well.
Robert
From rwatson at FreeBSD.org Sun Nov 1 16:41:07 2009
From: rwatson at FreeBSD.org (Robert Watson)
Date: Sun Nov 1 16:41:14 2009
Subject: svn commit: r198745 - in stable/8: etc sys sys/amd64/include/xen
sys/cddl/contrib/opensolaris sys/contrib/dev/acpica sys/contrib/pf
sys/dev/syscons sys/dev/xen/xenpci sys/kern sys/sys usr.sbin/jail
In-Reply-To: <20091101154335.GJ1293@hoeg.nl>
References: <200911011030.nA1AUVsN019962@svn.freebsd.org>
<20091101154335.GJ1293@hoeg.nl>
Message-ID:
On Sun, 1 Nov 2009, Ed Schouten wrote:
> * Robert Watson wrote:
>> Is there some relationship between the various changesets merged together
>> here? One nice thing about grouping merged changesets in some way is that
>> it makes backing them out more sensible if there's a problem (since you
>> just revert the whole changeset, etc).
>
> Well, it initially happened like this, because I wanted to merge back
> multiple changes back to releng/8 with re@'s approval. re@ required diff
> files to include commit messages and proper mergeinfo.
>
> Because I can't think of a way to prepare a larger set of patches that
> include proper mergeinfo without constantly reverting back and forth or
> keeping track of multiple 1.2 GB checkouts, I eventually just decided to
> create a bigger patch, so it was more an exception than a routine.
>
> Reverting patches shouldn't be a problem, because I could always just svn
> merge -c -123456 to revert individual commits.
I had more in mind that instructions to locally roll back particular
changesets to users will have weird side effects that they didn't have before.
Robert
From avg at FreeBSD.org Sun Nov 1 17:15:39 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 17:15:52 2009
Subject: svn commit: r198755 - stable/7/usr.bin/fstat
Message-ID: <200911011715.nA1HFcpG028973@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 17:15:38 2009
New Revision: 198755
URL: http://svn.freebsd.org/changeset/base/198755
Log:
MFC 196399: fstat: fix fsid comparison on systems with 64-bit long
Modified:
stable/7/usr.bin/fstat/ (props changed)
stable/7/usr.bin/fstat/fstat.c
stable/7/usr.bin/fstat/zfs.c
Modified: stable/7/usr.bin/fstat/fstat.c
==============================================================================
--- stable/7/usr.bin/fstat/fstat.c Sun Nov 1 17:05:08 2009 (r198754)
+++ stable/7/usr.bin/fstat/fstat.c Sun Nov 1 17:15:38 2009 (r198755)
@@ -649,7 +649,7 @@ devfs_filestat(struct vnode *vp, struct
(void *)devfs_dirent.de_vnode, Pid);
return 0;
}
- fsp->fsid = (long)mount.mnt_stat.f_fsid.val[0];
+ fsp->fsid = (long)(uint32_t)mount.mnt_stat.f_fsid.val[0];
fsp->fileid = devfs_dirent.de_inode;
fsp->mode = (devfs_dirent.de_mode & ~S_IFMT) | S_IFCHR;
fsp->size = 0;
Modified: stable/7/usr.bin/fstat/zfs.c
==============================================================================
--- stable/7/usr.bin/fstat/zfs.c Sun Nov 1 17:05:08 2009 (r198754)
+++ stable/7/usr.bin/fstat/zfs.c Sun Nov 1 17:15:38 2009 (r198755)
@@ -117,7 +117,7 @@ zfs_filestat(struct vnode *vp, struct fi
goto bad;
}
- fsp->fsid = (long)mount.mnt_stat.f_fsid.val[0];
+ fsp->fsid = (long)(uint32_t)mount.mnt_stat.f_fsid.val[0];
fsp->fileid = *zid;
/*
* XXX: Shows up wrong in output, but UFS has this error too. Could
From des at des.no Sun Nov 1 17:17:26 2009
From: des at des.no (=?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?=)
Date: Sun Nov 1 17:17:43 2009
Subject: svn commit: r198745 - in stable/8: etc sys
sys/amd64/include/xen sys/cddl/contrib/opensolaris
sys/contrib/dev/acpica sys/contrib/pf sys/dev/syscons
sys/dev/xen/xenpci sys/kern sys/sys usr.sbin/jail
In-Reply-To: <20091101154335.GJ1293@hoeg.nl> (Ed Schouten's message of "Sun, 1
Nov 2009 16:43:35 +0100")
References: <200911011030.nA1AUVsN019962@svn.freebsd.org>
<20091101154335.GJ1293@hoeg.nl>
Message-ID: <86hbtejhay.fsf@ds4.des.no>
Ed Schouten writes:
> Because I can't think of a way to prepare a larger set of patches that
> include proper mergeinfo without constantly reverting back and forth or
> keeping track of multiple 1.2 GB checkouts, I eventually just decided to
> create a bigger patch, so it was more an exception than a routine.
Use ZFS, snapshot a clean tree and create a separate clone for each
patchset.
DES
--
Dag-Erling Sm?rgrav - des@des.no
From avg at FreeBSD.org Sun Nov 1 17:36:37 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 17:36:44 2009
Subject: svn commit: r198756 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/xen/xenpci kern
Message-ID: <200911011736.nA1Haa10029490@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 17:36:36 2009
New Revision: 198756
URL: http://svn.freebsd.org/changeset/base/198756
Log:
MFC 197641: print_caddr_t: drop incorrect __unused from parameter
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
stable/8/sys/kern/init_main.c
Modified: stable/8/sys/kern/init_main.c
==============================================================================
--- stable/8/sys/kern/init_main.c Sun Nov 1 17:15:38 2009 (r198755)
+++ stable/8/sys/kern/init_main.c Sun Nov 1 17:36:36 2009 (r198756)
@@ -284,7 +284,7 @@ restart:
***************************************************************************
*/
static void
-print_caddr_t(void *data __unused)
+print_caddr_t(void *data)
{
printf("%s", (char *)data);
}
From avg at FreeBSD.org Sun Nov 1 17:37:03 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 17:37:11 2009
Subject: svn commit: r198757 - in stable/7/sys: . contrib/pf kern
Message-ID: <200911011737.nA1Hb3Kl029534@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 17:37:03 2009
New Revision: 198757
URL: http://svn.freebsd.org/changeset/base/198757
Log:
MFC 197641: print_caddr_t: drop incorrect __unused from parameter
Modified:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/kern/init_main.c
Modified: stable/7/sys/kern/init_main.c
==============================================================================
--- stable/7/sys/kern/init_main.c Sun Nov 1 17:36:36 2009 (r198756)
+++ stable/7/sys/kern/init_main.c Sun Nov 1 17:37:03 2009 (r198757)
@@ -284,7 +284,7 @@ restart:
***************************************************************************
*/
static void
-print_caddr_t(void *data __unused)
+print_caddr_t(void *data)
{
printf("%s", (char *)data);
}
From avg at FreeBSD.org Sun Nov 1 17:40:05 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 17:40:17 2009
Subject: svn commit: r198758 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/xen/xenpci kern
Message-ID: <200911011740.nA1He5i5029649@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 17:40:05 2009
New Revision: 198758
URL: http://svn.freebsd.org/changeset/base/198758
Log:
MFC 197658: print machine in kernel boot version string
PR: kern/126926
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
stable/8/sys/kern/init_main.c
Modified: stable/8/sys/kern/init_main.c
==============================================================================
--- stable/8/sys/kern/init_main.c Sun Nov 1 17:37:03 2009 (r198757)
+++ stable/8/sys/kern/init_main.c Sun Nov 1 17:40:05 2009 (r198758)
@@ -288,11 +288,24 @@ print_caddr_t(void *data)
{
printf("%s", (char *)data);
}
+
+static void
+print_version(void *data __unused)
+{
+ int len;
+
+ /* Strip a trailing newline from version. */
+ len = strlen(version);
+ while (len > 0 && version[len - 1] == '\n')
+ len--;
+ printf("%.*s %s\n", len, version, machine);
+}
+
SYSINIT(announce, SI_SUB_COPYRIGHT, SI_ORDER_FIRST, print_caddr_t,
copyright);
SYSINIT(trademark, SI_SUB_COPYRIGHT, SI_ORDER_SECOND, print_caddr_t,
trademark);
-SYSINIT(version, SI_SUB_COPYRIGHT, SI_ORDER_THIRD, print_caddr_t, version);
+SYSINIT(version, SI_SUB_COPYRIGHT, SI_ORDER_THIRD, print_version, NULL);
#ifdef WITNESS
static char wit_warn[] =
From avg at FreeBSD.org Sun Nov 1 17:43:00 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 17:43:16 2009
Subject: svn commit: r198759 - in stable/7/sys: . contrib/pf kern
Message-ID: <200911011742.nA1Hgx0N029751@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 17:42:59 2009
New Revision: 198759
URL: http://svn.freebsd.org/changeset/base/198759
Log:
MFC 197658: print machine in kernel boot version string
PR: kern/126926
Modified:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/kern/init_main.c
Modified: stable/7/sys/kern/init_main.c
==============================================================================
--- stable/7/sys/kern/init_main.c Sun Nov 1 17:40:05 2009 (r198758)
+++ stable/7/sys/kern/init_main.c Sun Nov 1 17:42:59 2009 (r198759)
@@ -288,11 +288,24 @@ print_caddr_t(void *data)
{
printf("%s", (char *)data);
}
+
+static void
+print_version(void *data __unused)
+{
+ int len;
+
+ /* Strip a trailing newline from version. */
+ len = strlen(version);
+ while (len > 0 && version[len - 1] == '\n')
+ len--;
+ printf("%.*s %s\n", len, version, machine);
+}
+
SYSINIT(announce, SI_SUB_COPYRIGHT, SI_ORDER_FIRST, print_caddr_t,
copyright);
SYSINIT(trademark, SI_SUB_COPYRIGHT, SI_ORDER_SECOND, print_caddr_t,
trademark);
-SYSINIT(version, SI_SUB_COPYRIGHT, SI_ORDER_THIRD, print_caddr_t, version);
+SYSINIT(version, SI_SUB_COPYRIGHT, SI_ORDER_THIRD, print_version, NULL);
#ifdef WITNESS
static char wit_warn[] =
From avg at FreeBSD.org Sun Nov 1 17:45:38 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 17:45:55 2009
Subject: svn commit: r198760 - in stable/8/sys: . amd64/include
amd64/include/xen cddl/contrib/opensolaris contrib/dev/acpica
contrib/pf dev/xen/xenpci i386/include
Message-ID: <200911011745.nA1HjbrE029892@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 17:45:37 2009
New Revision: 198760
URL: http://svn.freebsd.org/changeset/base/198760
Log:
MFC 197647: cpufunc.h: unify/correct style of c extension names
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/cpufunc.h
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
stable/8/sys/i386/include/cpufunc.h
Modified: stable/8/sys/amd64/include/cpufunc.h
==============================================================================
--- stable/8/sys/amd64/include/cpufunc.h Sun Nov 1 17:42:59 2009 (r198759)
+++ stable/8/sys/amd64/include/cpufunc.h Sun Nov 1 17:45:37 2009 (r198760)
@@ -277,7 +277,7 @@ static __inline void
mfence(void)
{
- __asm__ __volatile("mfence" : : : "memory");
+ __asm __volatile("mfence" : : : "memory");
}
static __inline void
@@ -457,14 +457,14 @@ load_es(u_int sel)
__asm __volatile("mov %0,%%es" : : "rm" (sel));
}
-static inline void
+static __inline void
cpu_monitor(const void *addr, int extensions, int hints)
{
__asm __volatile("monitor;"
: :"a" (addr), "c" (extensions), "d"(hints));
}
-static inline void
+static __inline void
cpu_mwait(int extensions, int hints)
{
__asm __volatile("mwait;" : :"a" (hints), "c" (extensions));
Modified: stable/8/sys/i386/include/cpufunc.h
==============================================================================
--- stable/8/sys/i386/include/cpufunc.h Sun Nov 1 17:42:59 2009 (r198759)
+++ stable/8/sys/i386/include/cpufunc.h Sun Nov 1 17:45:37 2009 (r198760)
@@ -132,14 +132,14 @@ enable_intr(void)
#endif
}
-static inline void
+static __inline void
cpu_monitor(const void *addr, int extensions, int hints)
{
__asm __volatile("monitor;"
: :"a" (addr), "c" (extensions), "d"(hints));
}
-static inline void
+static __inline void
cpu_mwait(int extensions, int hints)
{
__asm __volatile("mwait;" : :"a" (hints), "c" (extensions));
From avg at FreeBSD.org Sun Nov 1 17:53:33 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 17:53:39 2009
Subject: svn commit: r198761 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/xen/xenpci i386/conf
Message-ID: <200911011753.nA1HrXW0030108@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 17:53:33 2009
New Revision: 198761
URL: http://svn.freebsd.org/changeset/base/198761
Log:
MFC 198271: add amdtemp to i386 NOTES
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
stable/8/sys/i386/conf/NOTES
Modified: stable/8/sys/i386/conf/NOTES
==============================================================================
--- stable/8/sys/i386/conf/NOTES Sun Nov 1 17:45:37 2009 (r198760)
+++ stable/8/sys/i386/conf/NOTES Sun Nov 1 17:53:33 2009 (r198761)
@@ -786,8 +786,10 @@ device ichwd
# Temperature sensors:
#
# coretemp: on-die sensor on Intel Core and newer CPUs
+# amdtemp: on-die sensor on AMD K8/K10/K11 CPUs
#
device coretemp
+device amdtemp
#
# CPU control pseudo-device. Provides access to MSRs, CPUID info and
From avg at FreeBSD.org Sun Nov 1 17:54:49 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 17:54:55 2009
Subject: svn commit: r198762 - in stable/7/sys: . contrib/pf i386/conf
Message-ID: <200911011754.nA1HsngE030186@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 17:54:49 2009
New Revision: 198762
URL: http://svn.freebsd.org/changeset/base/198762
Log:
MFC 198271: add amdtemp to i386 NOTES
Modified:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/i386/conf/NOTES
Modified: stable/7/sys/i386/conf/NOTES
==============================================================================
--- stable/7/sys/i386/conf/NOTES Sun Nov 1 17:53:33 2009 (r198761)
+++ stable/7/sys/i386/conf/NOTES Sun Nov 1 17:54:49 2009 (r198762)
@@ -870,8 +870,10 @@ device ichwd
# Temperature sensors:
#
# coretemp: on-die sensor on Intel Core and newer CPUs
+# amdtemp: on-die sensor on AMD K8/K10/K11 CPUs
#
device coretemp
+device amdtemp
#---------------------------------------------------------------------------
# ISDN4BSD
From avg at FreeBSD.org Sun Nov 1 17:56:46 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 17:56:52 2009
Subject: svn commit: r198763 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/xen/xenpci modules
Message-ID: <200911011756.nA1HujOF030292@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 17:56:45 2009
New Revision: 198763
URL: http://svn.freebsd.org/changeset/base/198763
Log:
MFC 198279: fix sorting of some amd* entries in some makefiles
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
stable/8/sys/modules/Makefile
Modified: stable/8/sys/modules/Makefile
==============================================================================
--- stable/8/sys/modules/Makefile Sun Nov 1 17:54:49 2009 (r198762)
+++ stable/8/sys/modules/Makefile Sun Nov 1 17:56:45 2009 (r198763)
@@ -18,10 +18,10 @@ SUBDIR= ${_3dfx} \
${_aic} \
aic7xxx \
aio \
- ${_amd} \
- ${_amdtemp} \
alc \
ale \
+ ${_amd} \
+ ${_amdtemp} \
amr \
${_an} \
${_aout} \
From avg at FreeBSD.org Sun Nov 1 17:58:57 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 17:59:03 2009
Subject: svn commit: r198764 - in stable/7/sys: . contrib/pf modules
Message-ID: <200911011758.nA1HwvF8030392@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 17:58:56 2009
New Revision: 198764
URL: http://svn.freebsd.org/changeset/base/198764
Log:
MFC 198279: fix sorting of some amd* entries in some makefiles
Modified:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/modules/Makefile
Modified: stable/7/sys/modules/Makefile
==============================================================================
--- stable/7/sys/modules/Makefile Sun Nov 1 17:56:45 2009 (r198763)
+++ stable/7/sys/modules/Makefile Sun Nov 1 17:58:56 2009 (r198764)
@@ -16,10 +16,10 @@ SUBDIR= ${_3dfx} \
${_aic} \
aic7xxx \
aio \
- ${_amd} \
- ${_amdtemp} \
alc \
ale \
+ ${_amd} \
+ ${_amdtemp} \
amr \
${_an} \
${_aout} \
From avg at FreeBSD.org Sun Nov 1 18:10:39 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 18:10:51 2009
Subject: svn commit: r198765 - stable/8/share/man/man4
Message-ID: <200911011810.nA1IAc9A030827@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 18:10:38 2009
New Revision: 198765
URL: http://svn.freebsd.org/changeset/base/198765
Log:
MFC 198279: fix sorting of some amd* entries in some makefiles
Modified:
stable/8/share/man/man4/ (props changed)
stable/8/share/man/man4/Makefile
Modified: stable/8/share/man/man4/Makefile
==============================================================================
--- stable/8/share/man/man4/Makefile Sun Nov 1 17:58:56 2009 (r198764)
+++ stable/8/share/man/man4/Makefile Sun Nov 1 18:10:38 2009 (r198765)
@@ -30,8 +30,8 @@ MAN= aac.4 \
ale.4 \
altq.4 \
amd.4 \
- ${_amdtemp.4} \
${_amdsmb.4} \
+ ${_amdtemp.4} \
amr.4 \
an.4 \
arcmsr.4 \
From avg at FreeBSD.org Sun Nov 1 18:16:56 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 18:17:02 2009
Subject: svn commit: r198766 - stable/8/share/man/man4
Message-ID: <200911011816.nA1IGt7A031029@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 18:16:55 2009
New Revision: 198766
URL: http://svn.freebsd.org/changeset/base/198766
Log:
MFC 198272, 198288: fix watchdogd(8) reference
Modified:
stable/8/share/man/man4/ (props changed)
stable/8/share/man/man4/ichwd.4
Modified: stable/8/share/man/man4/ichwd.4
==============================================================================
--- stable/8/share/man/man4/ichwd.4 Sun Nov 1 18:10:38 2009 (r198765)
+++ stable/8/share/man/man4/ichwd.4 Sun Nov 1 18:16:55 2009 (r198766)
@@ -66,7 +66,7 @@ it believes the WDT is disabled.
.Sh SEE ALSO
.Xr watchdog 4 ,
.Xr watchdog 8 ,
-.Xr watchdogd 8,
+.Xr watchdogd 8 ,
.Xr watchdog 9
.Rs
.%T Using the Intel ICH Family Watchdog Timer (WDT)
From avg at FreeBSD.org Sun Nov 1 18:19:01 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 18:19:07 2009
Subject: svn commit: r198767 - stable/7/share/man/man4
Message-ID: <200911011819.nA1IJ0pq031144@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 18:19:00 2009
New Revision: 198767
URL: http://svn.freebsd.org/changeset/base/198767
Log:
MFC 198272, 198288: fix watchdogd(8) reference
Modified:
stable/7/share/man/man4/ (props changed)
stable/7/share/man/man4/ichwd.4
Modified: stable/7/share/man/man4/ichwd.4
==============================================================================
--- stable/7/share/man/man4/ichwd.4 Sun Nov 1 18:16:55 2009 (r198766)
+++ stable/7/share/man/man4/ichwd.4 Sun Nov 1 18:19:00 2009 (r198767)
@@ -66,7 +66,7 @@ it believes the WDT is disabled.
.Sh SEE ALSO
.Xr watchdog 4 ,
.Xr watchdog 8 ,
-.Xr watchdogd 8,
+.Xr watchdogd 8 ,
.Xr watchdog 9
.Rs
.%T Using the Intel ICH Family Watchdog Timer (WDT)
From brueffer at FreeBSD.org Sun Nov 1 18:25:11 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Sun Nov 1 18:25:23 2009
Subject: svn commit: r198768 - head/sbin/mknod
Message-ID: <200911011825.nA1IPBQ2031333@svn.freebsd.org>
Author: brueffer
Date: Sun Nov 1 18:25:11 2009
New Revision: 198768
URL: http://svn.freebsd.org/changeset/base/198768
Log:
Refine r198714, it's not as easy as just leaving the major number zero.
Submitted by: ed
MFC after: 1 week
Modified:
head/sbin/mknod/mknod.8
Modified: head/sbin/mknod/mknod.8
==============================================================================
--- head/sbin/mknod/mknod.8 Sun Nov 1 18:19:00 2009 (r198767)
+++ head/sbin/mknod/mknod.8 Sun Nov 1 18:25:11 2009 (r198768)
@@ -74,7 +74,6 @@ and pseudo devices, and are type
.It Ar major
The major device number is an integer number which tells the kernel
which device driver entry point to use.
-This is a compatibility shim and should be left zero.
.It Ar minor
The minor device number tells the kernel which subunit
the node corresponds to on the device; for example,
From avg at FreeBSD.org Sun Nov 1 18:39:27 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 18:39:38 2009
Subject: svn commit: r198769 - in stable/8/sys: . amd64/include/xen
amd64/pci cddl/contrib/opensolaris contrib/dev/acpica
contrib/pf dev/pci dev/xen/xenpci i386/pci
Message-ID: <200911011839.nA1IdQIL031721@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 18:39:26 2009
New Revision: 198769
URL: http://svn.freebsd.org/changeset/base/198769
Log:
MFC 197450: number of cleanups in i386 and amd64 pci md code
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/amd64/pci/pci_cfgreg.c
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/pci/pcireg.h
stable/8/sys/dev/xen/xenpci/ (props changed)
stable/8/sys/i386/pci/pci_cfgreg.c
Modified: stable/8/sys/amd64/pci/pci_cfgreg.c
==============================================================================
--- stable/8/sys/amd64/pci/pci_cfgreg.c Sun Nov 1 18:25:11 2009 (r198768)
+++ stable/8/sys/amd64/pci/pci_cfgreg.c Sun Nov 1 18:39:26 2009 (r198769)
@@ -181,9 +181,9 @@ pci_cfgenable(unsigned bus, unsigned slo
{
int dataport = 0;
- if (bus <= PCI_BUSMAX && slot < 32 && func <= PCI_FUNCMAX &&
- reg <= PCI_REGMAX && bytes != 3 && (unsigned) bytes <= 4 &&
- (reg & (bytes - 1)) == 0) {
+ if (bus <= PCI_BUSMAX && slot <= PCI_SLOTMAX && func <= PCI_FUNCMAX &&
+ (unsigned)reg <= PCI_REGMAX && bytes != 3 &&
+ (unsigned)bytes <= 4 && (reg & (bytes - 1)) == 0) {
outl(CONF1_ADDR_PORT, (1 << 31) | (bus << 16) | (slot << 11)
| (func << 8) | (reg & ~0x03));
dataport = CONF1_DATA_PORT + (reg & 0x03);
@@ -281,7 +281,7 @@ pcie_cfgregopen(uint64_t base, uint8_t m
* fall back to using type 1 config access instead.
*/
if (pci_cfgregopen() != 0) {
- for (slot = 0; slot < 32; slot++) {
+ for (slot = 0; slot <= PCI_SLOTMAX; slot++) {
val1 = pcireg_cfgread(0, slot, 0, 0, 4);
if (val1 == 0xffffffff)
continue;
@@ -309,8 +309,8 @@ pciereg_cfgread(int bus, unsigned slot,
volatile vm_offset_t va;
int data = -1;
- if (bus < pcie_minbus || bus > pcie_maxbus || slot >= 32 ||
- func > PCI_FUNCMAX || reg >= 0x1000)
+ if (bus < pcie_minbus || bus > pcie_maxbus || slot > PCI_SLOTMAX ||
+ func > PCI_FUNCMAX || reg > PCIE_REGMAX)
return (-1);
va = PCIE_VADDR(pcie_base, reg, bus, slot, func);
@@ -336,8 +336,8 @@ pciereg_cfgwrite(int bus, unsigned slot,
{
volatile vm_offset_t va;
- if (bus < pcie_minbus || bus > pcie_maxbus || slot >= 32 ||
- func > PCI_FUNCMAX || reg >= 0x1000)
+ if (bus < pcie_minbus || bus > pcie_maxbus || slot > PCI_SLOTMAX ||
+ func > PCI_FUNCMAX || reg > PCIE_REGMAX)
return;
va = PCIE_VADDR(pcie_base, reg, bus, slot, func);
Modified: stable/8/sys/dev/pci/pcireg.h
==============================================================================
--- stable/8/sys/dev/pci/pcireg.h Sun Nov 1 18:25:11 2009 (r198768)
+++ stable/8/sys/dev/pci/pcireg.h Sun Nov 1 18:39:26 2009 (r198769)
@@ -44,6 +44,7 @@
#define PCI_SLOTMAX 31 /* highest supported slot number */
#define PCI_FUNCMAX 7 /* highest supported function number */
#define PCI_REGMAX 255 /* highest supported config register addr. */
+#define PCIE_REGMAX 4095 /* highest supported config register addr. */
#define PCI_MAXHDRTYPE 2
/* PCI config header registers for all devices */
Modified: stable/8/sys/i386/pci/pci_cfgreg.c
==============================================================================
--- stable/8/sys/i386/pci/pci_cfgreg.c Sun Nov 1 18:25:11 2009 (r198768)
+++ stable/8/sys/i386/pci/pci_cfgreg.c Sun Nov 1 18:39:26 2009 (r198769)
@@ -299,9 +299,9 @@ pci_cfgenable(unsigned bus, unsigned slo
if (bus <= PCI_BUSMAX
&& slot < devmax
&& func <= PCI_FUNCMAX
- && reg <= PCI_REGMAX
+ && (unsigned)reg <= PCI_REGMAX
&& bytes != 3
- && (unsigned) bytes <= 4
+ && (unsigned)bytes <= 4
&& (reg & (bytes - 1)) == 0) {
switch (cfgmech) {
case CFGMECH_PCIE:
@@ -595,7 +595,7 @@ pcie_cfgregopen(uint64_t base, uint8_t m
* fall back to using type 1 config access instead.
*/
if (pci_cfgregopen() != 0) {
- for (slot = 0; slot < 32; slot++) {
+ for (slot = 0; slot <= PCI_SLOTMAX; slot++) {
val1 = pcireg_cfgread(0, slot, 0, 0, 4);
if (val1 == 0xffffffff)
continue;
@@ -661,8 +661,8 @@ pciereg_cfgread(int bus, unsigned slot,
vm_paddr_t pa, papage;
int data = -1;
- if (bus < pcie_minbus || bus > pcie_maxbus || slot >= 32 ||
- func > PCI_FUNCMAX || reg >= 0x1000 || bytes > 4 || bytes == 3)
+ if (bus < pcie_minbus || bus > pcie_maxbus || slot > PCI_SLOTMAX ||
+ func > PCI_FUNCMAX || reg > PCIE_REGMAX)
return (-1);
critical_enter();
@@ -695,8 +695,8 @@ pciereg_cfgwrite(int bus, unsigned slot,
volatile vm_offset_t va;
vm_paddr_t pa, papage;
- if (bus < pcie_minbus || bus > pcie_maxbus || slot >= 32 ||
- func > PCI_FUNCMAX || reg >= 0x1000)
+ if (bus < pcie_minbus || bus > pcie_maxbus || slot > PCI_SLOTMAX ||
+ func > PCI_FUNCMAX || reg > PCIE_REGMAX)
return;
critical_enter();
From avg at FreeBSD.org Sun Nov 1 18:40:03 2009
From: avg at FreeBSD.org (Andriy Gapon)
Date: Sun Nov 1 18:40:10 2009
Subject: svn commit: r198770 - in stable/7/sys: . amd64/pci contrib/pf
dev/pci i386/pci
Message-ID: <200911011840.nA1Ie3jC031779@svn.freebsd.org>
Author: avg
Date: Sun Nov 1 18:40:03 2009
New Revision: 198770
URL: http://svn.freebsd.org/changeset/base/198770
Log:
MFC 197450: number of cleanups in i386 and amd64 pci md code
Modified:
stable/7/sys/ (props changed)
stable/7/sys/amd64/pci/pci_cfgreg.c
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/dev/pci/pcireg.h
stable/7/sys/i386/pci/pci_cfgreg.c
Modified: stable/7/sys/amd64/pci/pci_cfgreg.c
==============================================================================
--- stable/7/sys/amd64/pci/pci_cfgreg.c Sun Nov 1 18:39:26 2009 (r198769)
+++ stable/7/sys/amd64/pci/pci_cfgreg.c Sun Nov 1 18:40:03 2009 (r198770)
@@ -181,9 +181,9 @@ pci_cfgenable(unsigned bus, unsigned slo
{
int dataport = 0;
- if (bus <= PCI_BUSMAX && slot < 32 && func <= PCI_FUNCMAX &&
- reg <= PCI_REGMAX && bytes != 3 && (unsigned) bytes <= 4 &&
- (reg & (bytes - 1)) == 0) {
+ if (bus <= PCI_BUSMAX && slot <= PCI_SLOTMAX && func <= PCI_FUNCMAX &&
+ (unsigned)reg <= PCI_REGMAX && bytes != 3 &&
+ (unsigned)bytes <= 4 && (reg & (bytes - 1)) == 0) {
outl(CONF1_ADDR_PORT, (1 << 31) | (bus << 16) | (slot << 11)
| (func << 8) | (reg & ~0x03));
dataport = CONF1_DATA_PORT + (reg & 0x03);
@@ -281,7 +281,7 @@ pcie_cfgregopen(uint64_t base, uint8_t m
* fall back to using type 1 config access instead.
*/
if (pci_cfgregopen() != 0) {
- for (slot = 0; slot < 32; slot++) {
+ for (slot = 0; slot <= PCI_SLOTMAX; slot++) {
val1 = pcireg_cfgread(0, slot, 0, 0, 4);
if (val1 == 0xffffffff)
continue;
@@ -309,8 +309,8 @@ pciereg_cfgread(int bus, unsigned slot,
volatile vm_offset_t va;
int data = -1;
- if (bus < pcie_minbus || bus > pcie_maxbus || slot >= 32 ||
- func > PCI_FUNCMAX || reg >= 0x1000)
+ if (bus < pcie_minbus || bus > pcie_maxbus || slot > PCI_SLOTMAX ||
+ func > PCI_FUNCMAX || reg > PCIE_REGMAX)
return (-1);
va = PCIE_VADDR(pcie_base, reg, bus, slot, func);
@@ -336,8 +336,8 @@ pciereg_cfgwrite(int bus, unsigned slot,
{
volatile vm_offset_t va;
- if (bus < pcie_minbus || bus > pcie_maxbus || slot >= 32 ||
- func > PCI_FUNCMAX || reg >= 0x1000)
+ if (bus < pcie_minbus || bus > pcie_maxbus || slot > PCI_SLOTMAX ||
+ func > PCI_FUNCMAX || reg > PCIE_REGMAX)
return;
va = PCIE_VADDR(pcie_base, reg, bus, slot, func);
Modified: stable/7/sys/dev/pci/pcireg.h
==============================================================================
--- stable/7/sys/dev/pci/pcireg.h Sun Nov 1 18:39:26 2009 (r198769)
+++ stable/7/sys/dev/pci/pcireg.h Sun Nov 1 18:40:03 2009 (r198770)
@@ -44,6 +44,7 @@
#define PCI_SLOTMAX 31 /* highest supported slot number */
#define PCI_FUNCMAX 7 /* highest supported function number */
#define PCI_REGMAX 255 /* highest supported config register addr. */
+#define PCIE_REGMAX 4095 /* highest supported config register addr. */
#define PCI_MAXHDRTYPE 2
/* PCI config header registers for all devices */
Modified: stable/7/sys/i386/pci/pci_cfgreg.c
==============================================================================
--- stable/7/sys/i386/pci/pci_cfgreg.c Sun Nov 1 18:39:26 2009 (r198769)
+++ stable/7/sys/i386/pci/pci_cfgreg.c Sun Nov 1 18:40:03 2009 (r198770)
@@ -291,9 +291,9 @@ pci_cfgenable(unsigned bus, unsigned slo
if (bus <= PCI_BUSMAX
&& slot < devmax
&& func <= PCI_FUNCMAX
- && reg <= PCI_REGMAX
+ && (unsigned)reg <= PCI_REGMAX
&& bytes != 3
- && (unsigned) bytes <= 4
+ && (unsigned)bytes <= 4
&& (reg & (bytes - 1)) == 0) {
switch (cfgmech) {
case CFGMECH_PCIE:
@@ -586,7 +586,7 @@ pcie_cfgregopen(uint64_t base, uint8_t m
* fall back to using type 1 config access instead.
*/
if (pci_cfgregopen() != 0) {
- for (slot = 0; slot < 32; slot++) {
+ for (slot = 0; slot <= PCI_SLOTMAX; slot++) {
val1 = pcireg_cfgread(0, slot, 0, 0, 4);
if (val1 == 0xffffffff)
continue;
@@ -651,8 +651,8 @@ pciereg_cfgread(int bus, unsigned slot,
vm_paddr_t pa, papage;
int data = -1;
- if (bus < pcie_minbus || bus > pcie_maxbus || slot >= 32 ||
- func > PCI_FUNCMAX || reg >= 0x1000 || bytes > 4 || bytes == 3)
+ if (bus < pcie_minbus || bus > pcie_maxbus || slot > PCI_SLOTMAX ||
+ func > PCI_FUNCMAX || reg > PCIE_REGMAX)
return (-1);
critical_enter();
@@ -685,8 +685,8 @@ pciereg_cfgwrite(int bus, unsigned slot,
volatile vm_offset_t va;
vm_paddr_t pa, papage;
- if (bus < pcie_minbus || bus > pcie_maxbus || slot >= 32 ||
- func > PCI_FUNCMAX || reg >= 0x1000)
+ if (bus < pcie_minbus || bus > pcie_maxbus || slot > PCI_SLOTMAX ||
+ func > PCI_FUNCMAX || reg > PCIE_REGMAX)
return;
critical_enter();
From kostikbel at gmail.com Sun Nov 1 18:43:37 2009
From: kostikbel at gmail.com (Kostik Belousov)
Date: Sun Nov 1 18:43:49 2009
Subject: svn commit: r198768 - head/sbin/mknod
In-Reply-To: <200911011825.nA1IPBQ2031333@svn.freebsd.org>
References: <200911011825.nA1IPBQ2031333@svn.freebsd.org>
Message-ID: <20091101184322.GP2147@deviant.kiev.zoral.com.ua>
On Sun, Nov 01, 2009 at 06:25:11PM +0000, Christian Brueffer wrote:
> Author: brueffer
> Date: Sun Nov 1 18:25:11 2009
> New Revision: 198768
> URL: http://svn.freebsd.org/changeset/base/198768
>
> Log:
> Refine r198714, it's not as easy as just leaving the major number zero.
>
> Submitted by: ed
> MFC after: 1 week
>
> Modified:
> head/sbin/mknod/mknod.8
>
> Modified: head/sbin/mknod/mknod.8
> ==============================================================================
> --- head/sbin/mknod/mknod.8 Sun Nov 1 18:19:00 2009 (r198767)
> +++ head/sbin/mknod/mknod.8 Sun Nov 1 18:25:11 2009 (r198768)
> @@ -74,7 +74,6 @@ and pseudo devices, and are type
> .It Ar major
> The major device number is an integer number which tells the kernel
> which device driver entry point to use.
> -This is a compatibility shim and should be left zero.
> .It Ar minor
> The minor device number tells the kernel which subunit
> the node corresponds to on the device; for example,
It seems that description of majors/minors there is absolutely irrelevant
to the freebsd device nodes. Devfs simply does not work this way anymore
for long time.
Moreover, you cannot create special node that would become a node used to
access device driver in the freebsd.
The only use that is left for mknod c|b is to create special nodes on
the filesystems exported by NFS for other un*xes.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091101/39a7501e/attachment.pgp
From alc at FreeBSD.org Sun Nov 1 18:48:07 2009
From: alc at FreeBSD.org (Alan Cox)
Date: Sun Nov 1 18:48:12 2009
Subject: svn commit: r198771 - in stable/8/gnu/usr.bin/groff: . tmac
Message-ID: <200911011848.nA1Im6D5032013@svn.freebsd.org>
Author: alc
Date: Sun Nov 1 18:48:06 2009
New Revision: 198771
URL: http://svn.freebsd.org/changeset/base/198771
Log:
MFC r197393
Add FreeBSD 7.2 and 7.3.
Modified:
stable/8/gnu/usr.bin/groff/ (props changed)
stable/8/gnu/usr.bin/groff/tmac/mdoc.local
Modified: stable/8/gnu/usr.bin/groff/tmac/mdoc.local
==============================================================================
--- stable/8/gnu/usr.bin/groff/tmac/mdoc.local Sun Nov 1 18:40:03 2009 (r198770)
+++ stable/8/gnu/usr.bin/groff/tmac/mdoc.local Sun Nov 1 18:48:06 2009 (r198771)
@@ -72,6 +72,8 @@
.ds doc-operating-system-FreeBSD-6.3 6.3
.ds doc-operating-system-FreeBSD-6.4 6.4
.ds doc-operating-system-FreeBSD-7.1 7.1
+.ds doc-operating-system-FreeBSD-7.2 7.2
+.ds doc-operating-system-FreeBSD-7.3 7.3
.ds doc-operating-system-FreeBSD-8.0 8.0
.
.\" Definitions not (yet) in doc-syms
From alc at FreeBSD.org Sun Nov 1 19:22:08 2009
From: alc at FreeBSD.org (Alan Cox)
Date: Sun Nov 1 19:22:15 2009
Subject: svn commit: r198772 - in stable/8: lib/libc/gen sys
sys/amd64/include/xen sys/cddl/contrib/opensolaris
sys/contrib/dev/acpica sys/contrib/pf sys/dev/xen/xenpci sys/sys
Message-ID: <200911011922.nA1JM8OY032946@svn.freebsd.org>
Author: alc
Date: Sun Nov 1 19:22:07 2009
New Revision: 198772
URL: http://svn.freebsd.org/changeset/base/198772
Log:
MFC r197331, r197394
Add getpagesizes(3).
Added:
stable/8/lib/libc/gen/getpagesizes.3
- copied, changed from r197331, head/lib/libc/gen/getpagesizes.3
stable/8/lib/libc/gen/getpagesizes.c
- copied unchanged from r197331, head/lib/libc/gen/getpagesizes.c
Modified:
stable/8/lib/libc/gen/ (props changed)
stable/8/lib/libc/gen/Makefile.inc
stable/8/lib/libc/gen/Symbol.map
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
stable/8/sys/sys/mman.h
Modified: stable/8/lib/libc/gen/Makefile.inc
==============================================================================
--- stable/8/lib/libc/gen/Makefile.inc Sun Nov 1 18:48:06 2009 (r198771)
+++ stable/8/lib/libc/gen/Makefile.inc Sun Nov 1 19:22:07 2009 (r198772)
@@ -15,7 +15,7 @@ SRCS+= __getosreldate.c __xuname.c \
getbootfile.c getbsize.c \
getcap.c getcwd.c getdomainname.c getgrent.c getgrouplist.c \
gethostname.c getloadavg.c getlogin.c getmntinfo.c getnetgrent.c \
- getosreldate.c getpagesize.c \
+ getosreldate.c getpagesize.c getpagesizes.c \
getpeereid.c getprogname.c getpwent.c getttyent.c \
getusershell.c getvfsbyname.c glob.c \
initgroups.c isatty.c isinf.c isnan.c jrand48.c lcong48.c \
@@ -51,8 +51,8 @@ MAN+= alarm.3 arc4random.3 \
getbootfile.3 getbsize.3 getcap.3 getcontext.3 getcwd.3 \
getdiskbyname.3 getdomainname.3 getfsent.3 \
getgrent.3 getgrouplist.3 gethostname.3 getloadavg.3 \
- getmntinfo.3 getnetgrent.3 getosreldate.3 \
- getpagesize.3 getpass.3 getpeereid.3 getprogname.3 getpwent.3 \
+ getmntinfo.3 getnetgrent.3 getosreldate.3 getpagesize.3 \
+ getpagesizes.3 getpass.3 getpeereid.3 getprogname.3 getpwent.3 \
getttyent.3 getusershell.3 getvfsbyname.3 \
glob.3 initgroups.3 isgreater.3 ldexp.3 lockf.3 makecontext.3 \
modf.3 \
Modified: stable/8/lib/libc/gen/Symbol.map
==============================================================================
--- stable/8/lib/libc/gen/Symbol.map Sun Nov 1 18:48:06 2009 (r198771)
+++ stable/8/lib/libc/gen/Symbol.map Sun Nov 1 19:22:07 2009 (r198772)
@@ -366,6 +366,10 @@ FBSD_1.1 {
tcsetsid;
};
+FBSD_1.2 {
+ getpagesizes;
+};
+
FBSDprivate_1.0 {
/* needed by thread libraries */
__thr_jtable;
Copied and modified: stable/8/lib/libc/gen/getpagesizes.3 (from r197331, head/lib/libc/gen/getpagesizes.3)
==============================================================================
--- head/lib/libc/gen/getpagesizes.3 Sat Sep 19 18:01:32 2009 (r197331, copy source)
+++ stable/8/lib/libc/gen/getpagesizes.3 Sun Nov 1 19:22:07 2009 (r198772)
@@ -24,7 +24,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd September 19, 2009
+.Dd September 21, 2009
.Dt GETPAGESIZES 3
.Os
.Sh NAME
@@ -94,5 +94,6 @@ function first appeared in Solaris 9.
This manual page was written in conjunction with a new but compatible
implementation that was first released in
.Fx 7.3 .
-.Sh AUTHOR
-.An Alan L. Cox Aq alc@cs.rice.edu
+.Sh AUTHORS
+This manual page was written by
+.An Alan L. Cox Aq alc@cs.rice.edu .
Copied: stable/8/lib/libc/gen/getpagesizes.c (from r197331, head/lib/libc/gen/getpagesizes.c)
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ stable/8/lib/libc/gen/getpagesizes.c Sun Nov 1 19:22:07 2009 (r198772, copy of r197331, head/lib/libc/gen/getpagesizes.c)
@@ -0,0 +1,78 @@
+/*-
+ * Copyright (c) 2009 Alan L. Cox
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+
+#include
+__FBSDID("$FreeBSD$");
+
+#include
+#include
+#include
+
+#include
+
+/*
+ * Retrieves page size information from the system. Specifically, returns the
+ * number of distinct page sizes that are supported by the system, if
+ * "pagesize" is NULL and "nelem" is 0. Otherwise, assigns up to "nelem" of
+ * the system-supported page sizes to consecutive elements of the array
+ * referenced by "pagesize", and returns the number of such page sizes that it
+ * assigned to the array. These page sizes are expressed in bytes.
+ *
+ * The implementation of this function does not directly or indirectly call
+ * malloc(3) or any other dynamic memory allocator that may itself call this
+ * function.
+ */
+int
+getpagesizes(size_t pagesize[], int nelem)
+{
+ static u_long ps[MAXPAGESIZES];
+ static int nops;
+ size_t size;
+ int i;
+
+ if (nelem < 0 || (nelem > 0 && pagesize == NULL)) {
+ errno = EINVAL;
+ return (-1);
+ }
+ /* Cache the result of the sysctl(2). */
+ if (nops == 0) {
+ size = sizeof(ps);
+ if (sysctlbyname("hw.pagesizes", ps, &size, NULL, 0) == -1)
+ return (-1);
+ /* Count the number of page sizes that are supported. */
+ nops = size / sizeof(ps[0]);
+ while (nops > 0 && ps[nops - 1] == 0)
+ nops--;
+ }
+ if (pagesize == NULL)
+ return (nops);
+ /* Return up to "nelem" page sizes from the cached result. */
+ if (nelem > nops)
+ nelem = nops;
+ for (i = 0; i < nelem; i++)
+ pagesize[i] = ps[i];
+ return (nelem);
+}
Modified: stable/8/sys/sys/mman.h
==============================================================================
--- stable/8/sys/sys/mman.h Sun Nov 1 18:48:06 2009 (r198771)
+++ stable/8/sys/sys/mman.h Sun Nov 1 19:22:07 2009 (r198772)
@@ -208,6 +208,7 @@ __BEGIN_DECLS
* posix_typed_mem_open().
*/
#if __BSD_VISIBLE
+int getpagesizes(size_t *, int);
int madvise(void *, size_t, int);
int mincore(const void *, size_t, char *);
int minherit(void *, size_t, int);
From kientzle at freebsd.org Sun Nov 1 20:14:29 2009
From: kientzle at freebsd.org (Tim Kientzle)
Date: Sun Nov 1 20:14:35 2009
Subject: svn commit: r198768 - head/sbin/mknod
In-Reply-To: <20091101184322.GP2147@deviant.kiev.zoral.com.ua>
References: <200911011825.nA1IPBQ2031333@svn.freebsd.org>
<20091101184322.GP2147@deviant.kiev.zoral.com.ua>
Message-ID: <4AEDEC24.2000206@freebsd.org>
Kostik Belousov wrote:
> On Sun, Nov 01, 2009 at 06:25:11PM +0000, Christian Brueffer wrote:
>> Author: brueffer
>> Date: Sun Nov 1 18:25:11 2009
>> New Revision: 198768
>> URL: http://svn.freebsd.org/changeset/base/198768
>>
>> Log:
>> Refine r198714, it's not as easy as just leaving the major number zero.
>>
>> Submitted by: ed
>> MFC after: 1 week
>>
>
> Moreover, you cannot create special node that would become a node used to
> access device driver in the freebsd.
>
> The only use that is left for mknod c|b is to create special nodes on
> the filesystems exported by NFS for other un*xes.
I wonder if mknod c|b should print a warning?
Tim
From ed at 80386.nl Sun Nov 1 20:22:43 2009
From: ed at 80386.nl (Ed Schouten)
Date: Sun Nov 1 20:22:50 2009
Subject: svn commit: r198768 - head/sbin/mknod
In-Reply-To: <20091101184322.GP2147@deviant.kiev.zoral.com.ua>
References: <200911011825.nA1IPBQ2031333@svn.freebsd.org>
<20091101184322.GP2147@deviant.kiev.zoral.com.ua>
Message-ID: <20091101202242.GK1293@hoeg.nl>
* Kostik Belousov wrote:
> It seems that description of majors/minors there is absolutely irrelevant
> to the freebsd device nodes. Devfs simply does not work this way anymore
> for long time.
Which is why I proposed changing these sentences to the past tense,
i.e.:
The major device number is an integer number which tells the
kernel which device driver entry point to use.
should become:
The major device number is an integer number which used to tell
the kernel which device driver entry point to use.
and:
The minor device number tells the kernel which subunit the node
corresponds to on the device; for example,
should become:
The minor device number used to tell the kernel which subunit
the node corresponds to on the device; for example,
Because there are also various discrepancies between how FreeBSD and
not-FreeBSD divide dev_t's into major and minor numbers, I would almost
suggest merging mknod(8)'s major and minor argument into one, namely a
(hexa)decimal 32-bit value.
--
Ed Schouten
WWW: http://80386.nl/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091101/8a0a4055/attachment.pgp
From alc at FreeBSD.org Sun Nov 1 20:24:17 2009
From: alc at FreeBSD.org (Alan Cox)
Date: Sun Nov 1 20:24:29 2009
Subject: svn commit: r198773 - in stable/8/lib/libc: . gen stdio stdtime
string
Message-ID: <200911012024.nA1KOHvi034442@svn.freebsd.org>
Author: alc
Date: Sun Nov 1 20:24:17 2009
New Revision: 198773
URL: http://svn.freebsd.org/changeset/base/198773
Log:
MFC r197163
Add the FBSD_1.2 namespace.
Reminded by: kib
Modified:
stable/8/lib/libc/ (props changed)
stable/8/lib/libc/Versions.def
stable/8/lib/libc/gen/ (props changed)
stable/8/lib/libc/stdio/asprintf.c (props changed)
stable/8/lib/libc/stdtime/ (props changed)
stable/8/lib/libc/string/ffsll.c (props changed)
stable/8/lib/libc/string/flsll.c (props changed)
stable/8/lib/libc/string/wcpcpy.c (props changed)
stable/8/lib/libc/string/wcpncpy.c (props changed)
Modified: stable/8/lib/libc/Versions.def
==============================================================================
--- stable/8/lib/libc/Versions.def Sun Nov 1 19:22:07 2009 (r198772)
+++ stable/8/lib/libc/Versions.def Sun Nov 1 20:24:17 2009 (r198773)
@@ -1,5 +1,11 @@
# $FreeBSD$
+#
+# Note: Whenever bumping the FBSD version, always make
+# FBSDprivate_1.0 depend on the new FBSD version.
+# This will keep it at the end of the dependency chain.
+#
+
# This is our first version; it depends on no other.
# This version was first added to 7.0-current.
FBSD_1.0 {
@@ -9,6 +15,10 @@ FBSD_1.0 {
FBSD_1.1 {
} FBSD_1.0;
+# This version was first added to 9.0-current.
+FBSD_1.2 {
+} FBSD_1.1;
+
# This is our private namespace. Any global interfaces that are
# strictly for use only by other FreeBSD applications and libraries
# are listed here. We use a separate namespace so we can write
@@ -16,4 +26,4 @@ FBSD_1.1 {
#
# Please do NOT increment the version of this namespace.
FBSDprivate_1.0 {
-} FBSD_1.1;
+} FBSD_1.2;
From thompsa at FreeBSD.org Sun Nov 1 21:03:51 2009
From: thompsa at FreeBSD.org (Andrew Thompson)
Date: Sun Nov 1 21:04:24 2009
Subject: svn commit: r198748 - in head/sys/cam: . ata scsi
In-Reply-To: <200911011131.nA1BV6lO022276@svn.freebsd.org>
References: <200911011131.nA1BV6lO022276@svn.freebsd.org>
Message-ID: <1280352d0911011303g1c07ec48o7782fc8974e65fa7@mail.gmail.com>
2009/11/2 Alexander Motin :
> Author: mav
> Date: Sun Nov ?1 11:31:06 2009
> New Revision: 198748
> URL: http://svn.freebsd.org/changeset/base/198748
>
> Log:
> ?MFp4:
> ?Fix reference counting bug, when device unreferenced before then
> ?invalidated. To do it, do not handle validity flag as another
> ?reference, but explicitly modify reference count each time flag is
> ?modified.
>
> ?Discovered by: ? ? ? ?thompsa
Thanks!
From thompsa at FreeBSD.org Sun Nov 1 21:41:44 2009
From: thompsa at FreeBSD.org (Andrew Thompson)
Date: Sun Nov 1 21:41:51 2009
Subject: svn commit: r198774 - head/sys/dev/usb/serial
Message-ID: <200911012141.nA1Lfi8r036062@svn.freebsd.org>
Author: thompsa
Date: Sun Nov 1 21:41:44 2009
New Revision: 198774
URL: http://svn.freebsd.org/changeset/base/198774
Log:
Check unit number and provide string name for consdev.
Submitted by: HPS
Modified:
head/sys/dev/usb/serial/usb_serial.c
Modified: head/sys/dev/usb/serial/usb_serial.c
==============================================================================
--- head/sys/dev/usb/serial/usb_serial.c Sun Nov 1 20:24:17 2009 (r198773)
+++ head/sys/dev/usb/serial/usb_serial.c Sun Nov 1 21:41:44 2009 (r198774)
@@ -1300,7 +1300,12 @@ CONSOLE_DRIVER(ucom);
static void
ucom_cnprobe(struct consdev *cp)
{
- cp->cn_pri = CN_NORMAL;
+ if (ucom_cons_unit != -1)
+ cp->cn_pri = CN_NORMAL;
+ else
+ cp->cn_pri = CN_DEAD;
+
+ strlcpy(cp->cn_name, "ucom", sizeof(cp->cn_name));
}
static void
From thompsa at FreeBSD.org Sun Nov 1 21:44:38 2009
From: thompsa at FreeBSD.org (Andrew Thompson)
Date: Sun Nov 1 21:44:45 2009
Subject: svn commit: r198775 - head/sys/dev/usb
Message-ID: <200911012144.nA1LiboX036178@svn.freebsd.org>
Author: thompsa
Date: Sun Nov 1 21:44:37 2009
New Revision: 198775
URL: http://svn.freebsd.org/changeset/base/198775
Log:
Fix a corner case where usbd_transfer_drain() can return too early if the
callback has dropped the mutex, leading to a panic.
Submitted by: HPS
MFC after: 3 days
Modified:
head/sys/dev/usb/usb_core.h
head/sys/dev/usb/usb_transfer.c
Modified: head/sys/dev/usb/usb_core.h
==============================================================================
--- head/sys/dev/usb/usb_core.h Sun Nov 1 21:41:44 2009 (r198774)
+++ head/sys/dev/usb/usb_core.h Sun Nov 1 21:44:37 2009 (r198775)
@@ -112,6 +112,7 @@ struct usb_xfer_flags_int {
uint8_t curr_dma_set:1; /* used by USB HC/DC driver */
uint8_t can_cancel_immed:1; /* set if USB transfer can be
* cancelled immediately */
+ uint8_t doing_callback:1; /* set if executing the callback */
};
/*
Modified: head/sys/dev/usb/usb_transfer.c
==============================================================================
--- head/sys/dev/usb/usb_transfer.c Sun Nov 1 21:41:44 2009 (r198774)
+++ head/sys/dev/usb/usb_transfer.c Sun Nov 1 21:44:37 2009 (r198775)
@@ -1797,8 +1797,18 @@ usbd_transfer_drain(struct usb_xfer *xfe
usbd_transfer_stop(xfer);
- while (usbd_transfer_pending(xfer)) {
+ while (usbd_transfer_pending(xfer) ||
+ xfer->flags_int.doing_callback) {
+
+ /*
+ * It is allowed that the callback can drop its
+ * transfer mutex. In that case checking only
+ * "usbd_transfer_pending()" is not enough to tell if
+ * the USB transfer is fully drained. We also need to
+ * check the internal "doing_callback" flag.
+ */
xfer->flags_int.draining = 1;
+
/*
* Wait until the current outstanding USB
* transfer is complete !
@@ -2043,6 +2053,9 @@ usbd_callback_wrapper(struct usb_xfer_qu
/* get next USB transfer in the queue */
info->done_q.curr = NULL;
+ /* set flag in case of drain */
+ xfer->flags_int.doing_callback = 1;
+
USB_BUS_UNLOCK(info->bus);
USB_BUS_LOCK_ASSERT(info->bus, MA_NOTOWNED);
@@ -2095,12 +2108,17 @@ usbd_callback_wrapper(struct usb_xfer_qu
if ((!xfer->flags_int.open) &&
(xfer->flags_int.started) &&
(xfer->usb_state == USB_ST_ERROR)) {
+ /* clear flag in case of drain */
+ xfer->flags_int.doing_callback = 0;
/* try to loop, but not recursivly */
usb_command_wrapper(&info->done_q, xfer);
return;
}
done:
+ /* clear flag in case of drain */
+ xfer->flags_int.doing_callback = 0;
+
/*
* Check if we are draining.
*/
From thompsa at FreeBSD.org Sun Nov 1 21:48:19 2009
From: thompsa at FreeBSD.org (Andrew Thompson)
Date: Sun Nov 1 21:48:25 2009
Subject: svn commit: r198776 - head/sys/dev/usb
Message-ID: <200911012148.nA1LmI6R036292@svn.freebsd.org>
Author: thompsa
Date: Sun Nov 1 21:48:18 2009
New Revision: 198776
URL: http://svn.freebsd.org/changeset/base/198776
Log:
- Add usb_fill_bulk_urb() and usb_bulk_msg() linux compat functions [1]
- Don't write actual length if the actual length pointer is NULL [2]
- correct Linux Compatibility error codes for short isochronous IN transfers
and make status field signed.
Submitted by: Leunam Elebek [1], Manuel Gebele [2]
Modified:
head/sys/dev/usb/usb_compat_linux.c
head/sys/dev/usb/usb_compat_linux.h
Modified: head/sys/dev/usb/usb_compat_linux.c
==============================================================================
--- head/sys/dev/usb/usb_compat_linux.c Sun Nov 1 21:44:37 2009 (r198775)
+++ head/sys/dev/usb/usb_compat_linux.c Sun Nov 1 21:48:18 2009 (r198776)
@@ -624,10 +624,11 @@ usb_start_wait_urb(struct urb *urb, usb_
done:
if (do_unlock)
mtx_unlock(&Giant);
- if (err) {
- *p_actlen = 0;
- } else {
- *p_actlen = urb->actual_length;
+ if (p_actlen != NULL) {
+ if (err)
+ *p_actlen = 0;
+ else
+ *p_actlen = urb->actual_length;
}
return (err);
}
@@ -1362,8 +1363,17 @@ usb_linux_isoc_callback(struct usb_xfer
for (x = 0; x < urb->number_of_packets; x++) {
uipd = urb->iso_frame_desc + x;
+ if (uipd->length > xfer->frlengths[x]) {
+ if (urb->transfer_flags & URB_SHORT_NOT_OK) {
+ /* XXX should be EREMOTEIO */
+ uipd->status = -EPIPE;
+ } else {
+ uipd->status = 0;
+ }
+ } else {
+ uipd->status = 0;
+ }
uipd->actual_length = xfer->frlengths[x];
- uipd->status = 0;
if (!xfer->flags.ext_buffer) {
usbd_copy_out(xfer->frbuffers, offset,
USB_ADD_BYTES(urb->transfer_buffer,
@@ -1385,8 +1395,8 @@ usb_linux_isoc_callback(struct usb_xfer
if (xfer->actlen < xfer->sumlen) {
/* short transfer */
if (urb->transfer_flags & URB_SHORT_NOT_OK) {
- urb->status = -EPIPE; /* XXX should be
- * EREMOTEIO */
+ /* XXX should be EREMOTEIO */
+ urb->status = -EPIPE;
} else {
urb->status = 0;
}
@@ -1482,6 +1492,7 @@ tr_setup:
/* Set zero for "actual_length" */
for (x = 0; x < urb->number_of_packets; x++) {
urb->iso_frame_desc[x].actual_length = 0;
+ urb->iso_frame_desc[x].status = urb->status;
}
/* call callback */
@@ -1663,3 +1674,58 @@ setup_bulk:
goto tr_setup;
}
}
+
+/*------------------------------------------------------------------------*
+ * usb_fill_bulk_urb
+ *------------------------------------------------------------------------*/
+void
+usb_fill_bulk_urb(struct urb *urb, struct usb_device *udev,
+ struct usb_host_endpoint *uhe, void *buf,
+ int length, usb_complete_t callback, void *arg)
+{
+ urb->dev = udev;
+ urb->endpoint = uhe;
+ urb->transfer_buffer = buf;
+ urb->transfer_buffer_length = length;
+ urb->complete = callback;
+ urb->context = arg;
+}
+
+/*------------------------------------------------------------------------*
+ * usb_bulk_msg
+ *
+ * NOTE: This function can also be used for interrupt endpoints!
+ *
+ * Return values:
+ * 0: Success
+ * Else: Failure
+ *------------------------------------------------------------------------*/
+int
+usb_bulk_msg(struct usb_device *udev, struct usb_host_endpoint *uhe,
+ void *data, int len, uint16_t *pactlen, usb_timeout_t timeout)
+{
+ struct urb *urb;
+ int err;
+
+ if (uhe == NULL)
+ return (-EINVAL);
+ if (len < 0)
+ return (-EINVAL);
+
+ err = usb_setup_endpoint(udev, uhe, 4096 /* bytes */);
+ if (err)
+ return (err);
+
+ urb = usb_alloc_urb(0, 0);
+ if (urb == NULL)
+ return (-ENOMEM);
+
+ usb_fill_bulk_urb(urb, udev, uhe, data, len,
+ usb_linux_wait_complete, NULL);
+
+ err = usb_start_wait_urb(urb, timeout, pactlen);
+
+ usb_free_urb(urb);
+
+ return (err);
+}
Modified: head/sys/dev/usb/usb_compat_linux.h
==============================================================================
--- head/sys/dev/usb/usb_compat_linux.h Sun Nov 1 21:44:37 2009 (r198775)
+++ head/sys/dev/usb/usb_compat_linux.h Sun Nov 1 21:48:18 2009 (r198776)
@@ -217,7 +217,7 @@ struct usb_iso_packet_descriptor {
* packets are usually back to back) */
uint16_t length; /* expected length */
uint16_t actual_length;
- uint16_t status;
+ int16_t status; /* transfer status */
};
/*
@@ -299,6 +299,11 @@ void usb_set_intfdata(struct usb_interfa
void usb_linux_register(void *arg);
void usb_linux_deregister(void *arg);
+void usb_fill_bulk_urb(struct urb *, struct usb_device *,
+ struct usb_host_endpoint *, void *, int, usb_complete_t, void *);
+int usb_bulk_msg(struct usb_device *, struct usb_host_endpoint *,
+ void *, int, uint16_t *, usb_timeout_t);
+
#define interface_to_usbdev(intf) (intf)->linux_udev
#define interface_to_bsddev(intf) (intf)->linux_udev
From des at des.no Sun Nov 1 21:55:21 2009
From: des at des.no (=?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?=)
Date: Sun Nov 1 21:55:35 2009
Subject: svn commit: r198768 - head/sbin/mknod
In-Reply-To: <20091101202242.GK1293@hoeg.nl> (Ed Schouten's message of "Sun, 1
Nov 2009 21:22:42 +0100")
References: <200911011825.nA1IPBQ2031333@svn.freebsd.org>
<20091101184322.GP2147@deviant.kiev.zoral.com.ua>
<20091101202242.GK1293@hoeg.nl>
Message-ID: <86y6mpj4fs.fsf@ds4.des.no>
Ed Schouten writes:
> Which is why I proposed changing these sentences to the past tense,
> i.e.:
>
> The major device number is an integer number which tells the
> kernel which device driver entry point to use.
>
> should become:
>
> The major device number is an integer number which used to tell
> the kernel which device driver entry point to use.
>
> and:
>
> The minor device number tells the kernel which subunit the node
> corresponds to on the device; for example,
>
> should become:
>
> The minor device number used to tell the kernel which subunit
> the node corresponds to on the device; for example,
How about replacing both paragraphs with
major, minor
Historically, a device number consisted of two parts: the major
number, which identified a device driver, and the minor number, which
identified an individual device handled by that driver. FreeBSD no
longer makes that distinction; each device has a unique system-wide
minor number, and the major number is always zero. However, the
distinction is still important when creating device nodes on a file
system intended for use by an older system.
(modulo errors in grammar and style)
The paragraph about b | c should be altered in a similar manner, to
emphasize that FreeBSD does not have block devices, but that block
device nodes can still be created for use by older systems.
DES
--
Dag-Erling Sm?rgrav - des@des.no
From ed at 80386.nl Sun Nov 1 22:05:36 2009
From: ed at 80386.nl (Ed Schouten)
Date: Sun Nov 1 22:05:47 2009
Subject: svn commit: r198768 - head/sbin/mknod
In-Reply-To: <86y6mpj4fs.fsf@ds4.des.no>
References: <200911011825.nA1IPBQ2031333@svn.freebsd.org>
<20091101184322.GP2147@deviant.kiev.zoral.com.ua>
<20091101202242.GK1293@hoeg.nl> <86y6mpj4fs.fsf@ds4.des.no>
Message-ID: <20091101220533.GL1293@hoeg.nl>
Hi Dag-Erling,
* Dag-Erling Sm?rgrav wrote:
> identified an individual device handled by that driver. FreeBSD no
> longer makes that distinction; each device has a unique system-wide
> minor number, and the major number is always zero. However, the
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
As pointed out earlier, this is not true. Major numbers can be non-zero.
| #define major(x) ((int)(((u_int)(x) >> 8)&0xff))
Devices 256-511 will have a major number of 1, etc.
Apart from that, I think there is also a fair amount of overlap with the
COMPATIBILITY section of the same manpage.
--
Ed Schouten
WWW: http://80386.nl/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091101/23293445/attachment.pgp
From des at des.no Sun Nov 1 22:37:39 2009
From: des at des.no (=?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?=)
Date: Sun Nov 1 22:37:51 2009
Subject: svn commit: r198768 - head/sbin/mknod
In-Reply-To: <20091101220533.GL1293@hoeg.nl> (Ed Schouten's message of "Sun, 1
Nov 2009 23:05:33 +0100")
References: <200911011825.nA1IPBQ2031333@svn.freebsd.org>
<20091101184322.GP2147@deviant.kiev.zoral.com.ua>
<20091101202242.GK1293@hoeg.nl> <86y6mpj4fs.fsf@ds4.des.no>
<20091101220533.GL1293@hoeg.nl>
Message-ID: <86tyxdj2h9.fsf@ds4.des.no>
Ed Schouten writes:
> > Dag-Erling Sm?rgrav writes:
> > identified an individual device handled by that driver. FreeBSD no
> > longer makes that distinction; each device has a unique system-wide
> > minor number, and the major number is always zero. However, the
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> As pointed out earlier, this is not true. Major numbers can be non-zero.
>
> | #define major(x) ((int)(((u_int)(x) >> 8)&0xff))
>
> Devices 256-511 will have a major number of 1, etc.
So:
Each device has a unique system-wide device number; the minor number
contains the eight least-significant bits, and the major number
contains the rest.
(device numbers are currently unsigned int; is there a reason not to
make them explicitly 32 bits wide, i.e. uint32_t?)
> Apart from that, I think there is also a fair amount of overlap with the
> COMPATIBILITY section of the same manpage.
Yeah, but who reads those? :)
DES
--
Dag-Erling Sm?rgrav - des@des.no
From ed at 80386.nl Sun Nov 1 22:39:49 2009
From: ed at 80386.nl (Ed Schouten)
Date: Sun Nov 1 22:39:56 2009
Subject: svn commit: r198768 - head/sbin/mknod
In-Reply-To: <86tyxdj2h9.fsf@ds4.des.no>
References: <200911011825.nA1IPBQ2031333@svn.freebsd.org>
<20091101184322.GP2147@deviant.kiev.zoral.com.ua>
<20091101202242.GK1293@hoeg.nl> <86y6mpj4fs.fsf@ds4.des.no>
<20091101220533.GL1293@hoeg.nl> <86tyxdj2h9.fsf@ds4.des.no>
Message-ID: <20091101223948.GN1293@hoeg.nl>
* Dag-Erling Sm?rgrav wrote:
> (device numbers are currently unsigned int; is there a reason not to
> make them explicitly 32 bits wide, i.e. uint32_t?)
I think it should explicitly use dev_t or something, right?
--
Ed Schouten
WWW: http://80386.nl/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091101/e72d1a39/attachment.pgp
From des at des.no Sun Nov 1 23:59:18 2009
From: des at des.no (=?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?=)
Date: Sun Nov 1 23:59:30 2009
Subject: svn commit: r198768 - head/sbin/mknod
In-Reply-To: <20091101223948.GN1293@hoeg.nl> (Ed Schouten's message of "Sun, 1
Nov 2009 23:39:48 +0100")
References: <200911011825.nA1IPBQ2031333@svn.freebsd.org>
<20091101184322.GP2147@deviant.kiev.zoral.com.ua>
<20091101202242.GK1293@hoeg.nl> <86y6mpj4fs.fsf@ds4.des.no>
<20091101220533.GL1293@hoeg.nl> <86tyxdj2h9.fsf@ds4.des.no>
<20091101223948.GN1293@hoeg.nl>
Message-ID: <86pr81iyp7.fsf@ds4.des.no>
Ed Schouten writes:
> Dag-Erling Sm?rgrav writes:
> > (device numbers are currently unsigned int; is there a reason not to
> > make them explicitly 32 bits wide, i.e. uint32_t?)
> I think it should explicitly use dev_t or something, right?
Ah, I was looking in the wrong header; it is indeed a uint32_t. So:
b | c
Type of device. Historically, block devices were provided to allow
byte-level access to hardware that required data to be read or written
in fixed-sized blocks. FreeBSD no longer has block devices, and all
device nodes should be created as character devices.
However, the distinction between block and character devices is still
important when creating device nodes on a filesystem intended for use
by older systems.
(it's been so long since we dropped block devices that I actually had to
look up the details in an old copy of D&I)
major, minor
Historically, a device number consisted of two parts: the major
number, which identified a device driver, and the minor number, which
identified an individual device handled by that driver. FreeBSD no
longer makes that distinction. Instead, every device in the system
has a unique 32-bit device number. For compatibility with software
that still expects separate major and minor numbers, this 32-bit
device number is split into a 24-bit major number and an 8-bit minor
number.
However, the distinction between major and minor numbers is still
important when creating device nodes on a filesystem intended for use
by older systems.
DES
--
Dag-Erling Sm?rgrav - des@des.no
From thompsa at FreeBSD.org Mon Nov 2 03:28:41 2009
From: thompsa at FreeBSD.org (Andrew Thompson)
Date: Mon Nov 2 03:29:19 2009
Subject: svn commit: r198748 - in head/sys/cam: . ata scsi
In-Reply-To: <1280352d0911011907k34498c71g5b49ffb7220c377b@mail.gmail.com>
References: <200911011131.nA1BV6lO022276@svn.freebsd.org>
<1280352d0911011907k34498c71g5b49ffb7220c377b@mail.gmail.com>
Message-ID: <20091102031318.GB49898@citylink.fud.org.nz>
> Author: mav
> Date: Sun Nov 1 11:31:06 2009
> New Revision: 198748
> URL: http://svn.freebsd.org/changeset/base/198748
>
> Log:
> MFp4:
> Fix reference counting bug, when device unreferenced before then
> invalidated. To do it, do not handle validity flag as another
> reference, but explicitly modify reference count each time flag is
> modified.
There is still one problem with this. In xpt_async() we go through the
device list on the target and call the async function followed by
xpt_async_bcast(). With the above change its possible for
scsi_dev_async() to free the device due to dropping the
CAM_DEV_UNCONFIGURED flag, leading to a panic in xpt_async_bcast() on
freed memory.
This fixes it for me.
Index: cam/cam_xpt.c
===================================================================
--- cam/cam_xpt.c (revision 198779)
+++ cam/cam_xpt.c (working copy)
@@ -4023,12 +4023,15 @@ xpt_async(u_int32_t async_code, struct cam_path *p
&& device->lun_id != CAM_LUN_WILDCARD)
continue;
+ /* The async callback could free the device */
+ xpt_acquire_device(device);
(*(bus->xport->async))(async_code, bus,
target, device,
async_arg);
xpt_async_bcast(&device->asyncs, async_code,
path, async_arg);
+ xpt_release_device(device);
}
}
From hrs at FreeBSD.org Mon Nov 2 06:36:55 2009
From: hrs at FreeBSD.org (Hiroki Sato)
Date: Mon Nov 2 06:37:01 2009
Subject: svn commit: r198780 - in releng/8.0/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/usb/input dev/xen/xenpci
Message-ID: <200911020636.nA26asBM047828@svn.freebsd.org>
Author: hrs
Date: Mon Nov 2 06:36:54 2009
New Revision: 198780
URL: http://svn.freebsd.org/changeset/base/198780
Log:
MFC r197999:
Fix the 106/109 USB Japanese keyboard "underscore" issue.
Sun Type 6 USB keyboard support (added in rev 1.46) conflicted with
some scan codes used in Japanese keyboards because the scan code
conversion routine was ambiguous for the overlapped codes.
PR: ports/134005
Submitted by: YAMASHIRO Jun
Approved by: re (kib)
Modified:
releng/8.0/sys/ (props changed)
releng/8.0/sys/amd64/include/xen/ (props changed)
releng/8.0/sys/cddl/contrib/opensolaris/ (props changed)
releng/8.0/sys/contrib/dev/acpica/ (props changed)
releng/8.0/sys/contrib/pf/ (props changed)
releng/8.0/sys/dev/usb/input/ukbd.c
releng/8.0/sys/dev/xen/xenpci/ (props changed)
Modified: releng/8.0/sys/dev/usb/input/ukbd.c
==============================================================================
--- releng/8.0/sys/dev/usb/input/ukbd.c Mon Nov 2 00:41:10 2009 (r198779)
+++ releng/8.0/sys/dev/usb/input/ukbd.c Mon Nov 2 06:36:54 2009 (r198780)
@@ -247,8 +247,8 @@ static const uint8_t ukbd_trtab[256] = {
NN, NN, NN, NN, NN, NN, NN, NN, /* 68 - 6F */
NN, NN, NN, NN, 115, 108, 111, 113, /* 70 - 77 */
109, 110, 112, 118, 114, 116, 117, 119, /* 78 - 7F */
- 121, 120, NN, NN, NN, NN, NN, 115, /* 80 - 87 */
- 112, 125, 121, 123, NN, NN, NN, NN, /* 88 - 8F */
+ 121, 120, NN, NN, NN, NN, NN, 123, /* 80 - 87 */
+ 124, 125, 126, 127, 128, NN, NN, NN, /* 88 - 8F */
NN, NN, NN, NN, NN, NN, NN, NN, /* 90 - 97 */
NN, NN, NN, NN, NN, NN, NN, NN, /* 98 - 9F */
NN, NN, NN, NN, NN, NN, NN, NN, /* A0 - A7 */
@@ -1636,20 +1636,59 @@ static int
ukbd_key2scan(struct ukbd_softc *sc, int code, int shift, int up)
{
static const int scan[] = {
- 0x1c, 0x1d, 0x35,
- 0x37 | SCAN_PREFIX_SHIFT, /* PrintScreen */
- 0x38, 0x47, 0x48, 0x49, 0x4b, 0x4d, 0x4f,
- 0x50, 0x51, 0x52, 0x53,
- 0x46, /* XXX Pause/Break */
- 0x5b, 0x5c, 0x5d,
+ /* 89 */
+ 0x11c, /* Enter */
+ /* 90-99 */
+ 0x11d, /* Ctrl-R */
+ 0x135, /* Divide */
+ 0x137 | SCAN_PREFIX_SHIFT, /* PrintScreen */
+ 0x138, /* Alt-R */
+ 0x147, /* Home */
+ 0x148, /* Up */
+ 0x149, /* PageUp */
+ 0x14b, /* Left */
+ 0x14d, /* Right */
+ 0x14f, /* End */
+ /* 100-109 */
+ 0x150, /* Down */
+ 0x151, /* PageDown */
+ 0x152, /* Insert */
+ 0x153, /* Delete */
+ 0x146, /* XXX Pause/Break */
+ 0x15b, /* Win_L(Super_L) */
+ 0x15c, /* Win_R(Super_R) */
+ 0x15d, /* Application(Menu) */
+
/* SUN TYPE 6 USB KEYBOARD */
- 0x68, 0x5e, 0x5f, 0x60, 0x61, 0x62, 0x63,
- 0x64, 0x65, 0x66, 0x67, 0x25, 0x1f, 0x1e,
- 0x20,
+ 0x168, /* Sun Type 6 Help */
+ 0x15e, /* Sun Type 6 Stop */
+ /* 110 - 119 */
+ 0x15f, /* Sun Type 6 Again */
+ 0x160, /* Sun Type 6 Props */
+ 0x161, /* Sun Type 6 Undo */
+ 0x162, /* Sun Type 6 Front */
+ 0x163, /* Sun Type 6 Copy */
+ 0x164, /* Sun Type 6 Open */
+ 0x165, /* Sun Type 6 Paste */
+ 0x166, /* Sun Type 6 Find */
+ 0x167, /* Sun Type 6 Cut */
+ 0x125, /* Sun Type 6 Mute */
+ /* 120 - 128 */
+ 0x11f, /* Sun Type 6 VolumeDown */
+ 0x11e, /* Sun Type 6 VolumeUp */
+ 0x120, /* Sun Type 6 PowerDown */
+
+ /* Japanese 106/109 keyboard */
+ 0x73, /* Keyboard Intl' 1 (backslash / underscore) */
+ 0x70, /* Keyboard Intl' 2 (Katakana / Hiragana) */
+ 0x7d, /* Keyboard Intl' 3 (Yen sign) (Not using in jp106/109) */
+ 0x79, /* Keyboard Intl' 4 (Henkan) */
+ 0x7b, /* Keyboard Intl' 5 (Muhenkan) */
+ 0x5c, /* Keyboard Intl' 6 (Keypad ,) (For PC-9821 layout) */
};
if ((code >= 89) && (code < (89 + (sizeof(scan) / sizeof(scan[0]))))) {
- code = scan[code - 89] | SCAN_PREFIX_E0;
+ code = scan[code - 89];
}
/* Pause/Break */
if ((code == 104) && (!(shift & (MOD_CONTROL_L | MOD_CONTROL_R)))) {
From cperciva at FreeBSD.org Mon Nov 2 07:21:14 2009
From: cperciva at FreeBSD.org (Colin Percival)
Date: Mon Nov 2 07:21:24 2009
Subject: svn commit: r198781 - head/lib/libc/sys
Message-ID: <200911020721.nA27LDq1048764@svn.freebsd.org>
Author: cperciva
Date: Mon Nov 2 07:21:13 2009
New Revision: 198781
URL: http://svn.freebsd.org/changeset/base/198781
Log:
Attempt to reduce accidental foot-shooting by pointing out that
accept(2)ed sockets do not necessarily inherit O_NONBLOCK from
listening sockets on non-FreeBSD platforms.
Feet shot: cperciva
MFC after: 1 month
Modified:
head/lib/libc/sys/accept.2
Modified: head/lib/libc/sys/accept.2
==============================================================================
--- head/lib/libc/sys/accept.2 Mon Nov 2 06:36:54 2009 (r198780)
+++ head/lib/libc/sys/accept.2 Mon Nov 2 07:21:13 2009 (r198781)
@@ -126,6 +126,10 @@ new socket.
For some applications, performance may be enhanced by using an
.Xr accept_filter 9
to pre-process incoming connections.
+.Pp
+Portable programs should not rely on the
+.Dv O_NONBLOCK
+property being inherited.
.Sh RETURN VALUES
The call returns \-1 on error.
If it succeeds, it returns a non-negative
From mav at FreeBSD.org Mon Nov 2 08:31:01 2009
From: mav at FreeBSD.org (Alexander Motin)
Date: Mon Nov 2 08:31:12 2009
Subject: svn commit: r198782 - head/sys/cam
Message-ID: <200911020831.nA28V0iI050188@svn.freebsd.org>
Author: mav
Date: Mon Nov 2 08:31:00 2009
New Revision: 198782
URL: http://svn.freebsd.org/changeset/base/198782
Log:
The async callback could free the device. If it is a broadcast async,
it doesn't hold device reference, so take our own reference.
Submitted by: thompsa
Modified:
head/sys/cam/cam_xpt.c
Modified: head/sys/cam/cam_xpt.c
==============================================================================
--- head/sys/cam/cam_xpt.c Mon Nov 2 07:21:13 2009 (r198781)
+++ head/sys/cam/cam_xpt.c Mon Nov 2 08:31:00 2009 (r198782)
@@ -4022,13 +4022,19 @@ xpt_async(u_int32_t async_code, struct c
&& path->device->lun_id != CAM_LUN_WILDCARD
&& device->lun_id != CAM_LUN_WILDCARD)
continue;
-
+ /*
+ * The async callback could free the device.
+ * If it is a broadcast async, it doesn't hold
+ * device reference, so take our own reference.
+ */
+ xpt_acquire_device(device);
(*(bus->xport->async))(async_code, bus,
target, device,
async_arg);
xpt_async_bcast(&device->asyncs, async_code,
path, async_arg);
+ xpt_release_device(device);
}
}
From fjoe at FreeBSD.org Mon Nov 2 09:47:16 2009
From: fjoe at FreeBSD.org (Max Khon)
Date: Mon Nov 2 09:47:28 2009
Subject: svn commit: r198783 - stable/8/sys/tools
Message-ID: <200911020947.nA29lFbr051832@svn.freebsd.org>
Author: fjoe
Date: Mon Nov 2 09:47:15 2009
New Revision: 198783
URL: http://svn.freebsd.org/changeset/base/198783
Log:
MFC: Allow KMOD with hypens and dots.
Modified:
stable/8/sys/tools/fw_stub.awk
Modified: stable/8/sys/tools/fw_stub.awk
==============================================================================
--- stable/8/sys/tools/fw_stub.awk Mon Nov 2 08:31:00 2009 (r198782)
+++ stable/8/sys/tools/fw_stub.awk Mon Nov 2 09:47:15 2009 (r198783)
@@ -118,6 +118,8 @@ if (!num_files || !opt_m)
cfilename = opt_c;
ctmpfilename = cfilename ".tmp";
+modname = opt_m;
+gsub(/[-\.]/, "_", modname);
printc("#include \
#include \
@@ -139,7 +141,7 @@ for (file_i = 0; file_i < num_files; fil
}
printc("\nstatic int\n"\
-opt_m "_fw_modevent(module_t mod, int type, void *unused)\
+modname "_fw_modevent(module_t mod, int type, void *unused)\
{\
const struct firmware *fp, *parent;\
int error;\
@@ -206,14 +208,14 @@ printc("\t\treturn (error);\
return (EINVAL);\
}\
\
-static moduledata_t " opt_m "_fw_mod = {\
- \"" opt_m "_fw\",\
- " opt_m "_fw_modevent,\
+static moduledata_t " modname "_fw_mod = {\
+ \"" modname "_fw\",\
+ " modname "_fw_modevent,\
0\
};\
-DECLARE_MODULE(" opt_m "_fw, " opt_m "_fw_mod, SI_SUB_DRIVERS, SI_ORDER_FIRST);\
-MODULE_VERSION(" opt_m "_fw, 1);\
-MODULE_DEPEND(" opt_m "_fw, firmware, 1, 1, 1);\
+DECLARE_MODULE(" modname "_fw, " modname "_fw_mod, SI_SUB_DRIVERS, SI_ORDER_FIRST);\
+MODULE_VERSION(" modname "_fw, 1);\
+MODULE_DEPEND(" modname "_fw, firmware, 1, 1, 1);\
");
if (opt_c)
From fjoe at FreeBSD.org Mon Nov 2 09:47:41 2009
From: fjoe at FreeBSD.org (Max Khon)
Date: Mon Nov 2 09:47:59 2009
Subject: svn commit: r198784 - stable/7/sys/tools
Message-ID: <200911020947.nA29lfNG051881@svn.freebsd.org>
Author: fjoe
Date: Mon Nov 2 09:47:41 2009
New Revision: 198784
URL: http://svn.freebsd.org/changeset/base/198784
Log:
MFC: Allow KMOD with hypens and dots.
Modified:
stable/7/sys/tools/fw_stub.awk
Modified: stable/7/sys/tools/fw_stub.awk
==============================================================================
--- stable/7/sys/tools/fw_stub.awk Mon Nov 2 09:47:15 2009 (r198783)
+++ stable/7/sys/tools/fw_stub.awk Mon Nov 2 09:47:41 2009 (r198784)
@@ -118,6 +118,8 @@ if (!num_files || !opt_m)
cfilename = opt_c;
ctmpfilename = cfilename ".tmp";
+modname = opt_m;
+gsub(/[-\.]/, "_", modname);
printc("#include \
#include \
@@ -139,7 +141,7 @@ for (file_i = 0; file_i < num_files; fil
}
printc("\nstatic int\n"\
-opt_m "_fw_modevent(module_t mod, int type, void *unused)\
+modname "_fw_modevent(module_t mod, int type, void *unused)\
{\
const struct firmware *fp, *parent;\
int error;\
@@ -206,14 +208,14 @@ printc("\t\treturn (error);\
return (EINVAL);\
}\
\
-static moduledata_t " opt_m "_fw_mod = {\
- \"" opt_m "_fw\",\
- " opt_m "_fw_modevent,\
+static moduledata_t " modname "_fw_mod = {\
+ \"" modname "_fw\",\
+ " modname "_fw_modevent,\
0\
};\
-DECLARE_MODULE(" opt_m "_fw, " opt_m "_fw_mod, SI_SUB_DRIVERS, SI_ORDER_FIRST);\
-MODULE_VERSION(" opt_m "_fw, 1);\
-MODULE_DEPEND(" opt_m "_fw, firmware, 1, 1, 1);\
+DECLARE_MODULE(" modname "_fw, " modname "_fw_mod, SI_SUB_DRIVERS, SI_ORDER_FIRST);\
+MODULE_VERSION(" modname "_fw, 1);\
+MODULE_DEPEND(" modname "_fw, firmware, 1, 1, 1);\
");
if (opt_c)
From remko at FreeBSD.org Mon Nov 2 09:56:47 2009
From: remko at FreeBSD.org (Remko Lodder)
Date: Mon Nov 2 09:56:53 2009
Subject: svn commit: r198785 - head/etc/rc.d
Message-ID: <200911020956.nA29ukQo052099@svn.freebsd.org>
Author: remko
Date: Mon Nov 2 09:56:46 2009
New Revision: 198785
URL: http://svn.freebsd.org/changeset/base/198785
Log:
Execute the start/stop process of a jail in the background.
This will prevent that the script hangs during startup, which
could cause annoying effects after rebooting for example.
PR: kern/139422
Submitted by: Andrey Groshev
Approved by: imp (mentor, implicit)
MFC after: 3 days
Facilitated by: Snow B.V.
Modified:
head/etc/rc.d/jail
Modified: head/etc/rc.d/jail
==============================================================================
--- head/etc/rc.d/jail Mon Nov 2 09:47:41 2009 (r198784)
+++ head/etc/rc.d/jail Mon Nov 2 09:56:46 2009 (r198785)
@@ -728,4 +728,4 @@ fi
if [ -n "$*" ]; then
jail_list="$*"
fi
-run_rc_command "${cmd}"
+run_rc_command "${cmd}" &
From dwmalone at maths.tcd.ie Mon Nov 2 10:04:39 2009
From: dwmalone at maths.tcd.ie (David Malone)
Date: Mon Nov 2 10:04:50 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To: <20091101011212.GG1293@hoeg.nl>
References: <200910311035.n9VAZfIb082932@svn.freebsd.org>
<20091031.190353.-332187386.imp@bsdimp.com>
<20091101011212.GG1293@hoeg.nl>
Message-ID: <20091102100435.GA67211@walton.maths.tcd.ie>
On Sun, Nov 01, 2009 at 02:12:12AM +0100, Ed Schouten wrote:
> No, we don't. All these fields are not used by drivers, just some old
> version of the devfs code. I made sure struct cdevsw didn't change in
> size, so there should be no API nor ABI conflicts.
Surely it is an API change, but not an ABI change? Code that used
to do:
d.d_uid = 3;
will no longer compile, but code that was comipled with the old
version will still run. I understand that the assignment doesn't
do anything useful, but I suppose there still could be code that
does it?
David.
From ed at 80386.nl Mon Nov 2 10:24:05 2009
From: ed at 80386.nl (Ed Schouten)
Date: Mon Nov 2 10:24:17 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To: <20091102100435.GA67211@walton.maths.tcd.ie>
References: <200910311035.n9VAZfIb082932@svn.freebsd.org>
<20091031.190353.-332187386.imp@bsdimp.com>
<20091101011212.GG1293@hoeg.nl>
<20091102100435.GA67211@walton.maths.tcd.ie>
Message-ID: <20091102102404.GP1293@hoeg.nl>
Hello David,
* David Malone wrote:
> Surely it is an API change, but not an ABI change? Code that used
> to do:
>
> d.d_uid = 3;
>
> will no longer compile, but code that was comipled with the old
> version will still run. I understand that the assignment doesn't
> do anything useful, but I suppose there still could be code that
> does it?
Yes, in theory there could be pieces of code that do that, but keep in
mind that d_uid was never meant to be used by device drivers. It was
used by devfs internally, before cdevpriv existed.
Looking at the SVN logs, it was introduced in March 2005, but it was
already rendered useless in September that same year, when devfs was
modified to just obtain the ownership/modes from the cdevpriv instead of
the cdevsw.
Interesting commits:
- http://svn.freebsd.org/viewvc/base?view=revision&revision=143746
- http://svn.freebsd.org/viewvc/base?view=revision&revision=150342
--
Ed Schouten
WWW: http://80386.nl/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091102/c136ef04/attachment.pgp
From rpaulo at FreeBSD.org Mon Nov 2 11:07:42 2009
From: rpaulo at FreeBSD.org (Rui Paulo)
Date: Mon Nov 2 11:10:43 2009
Subject: svn commit: r198786 - in head/sys: compat/ndis dev/if_ndis
Message-ID: <200911021107.nA2B7gP4054855@svn.freebsd.org>
Author: rpaulo
Date: Mon Nov 2 11:07:42 2009
New Revision: 198786
URL: http://svn.freebsd.org/changeset/base/198786
Log:
Big style cleanup. While there remove references to FreeBSD versions
older than 6.0.
Submitted by: Paul B Mahol
Modified:
head/sys/compat/ndis/kern_ndis.c
head/sys/compat/ndis/kern_windrv.c
head/sys/compat/ndis/subr_hal.c
head/sys/compat/ndis/subr_ndis.c
head/sys/compat/ndis/subr_ntoskrnl.c
head/sys/compat/ndis/subr_pe.c
head/sys/compat/ndis/subr_usbd.c
head/sys/dev/if_ndis/if_ndis.c
head/sys/dev/if_ndis/if_ndis_usb.c
Modified: head/sys/compat/ndis/kern_ndis.c
==============================================================================
--- head/sys/compat/ndis/kern_ndis.c Mon Nov 2 09:56:46 2009 (r198785)
+++ head/sys/compat/ndis/kern_ndis.c Mon Nov 2 11:07:42 2009 (r198786)
@@ -184,7 +184,7 @@ ndis_modevent(module_t mod, int cmd, voi
break;
}
- return(error);
+ return (error);
}
DEV_MODULE(ndisapi, ndis_modevent, NULL);
MODULE_VERSION(ndisapi, 1);
@@ -193,7 +193,6 @@ static void
ndis_sendrsrcavail_func(adapter)
ndis_handle adapter;
{
- return;
}
static void
@@ -211,8 +210,7 @@ ndis_status_func(adapter, status, sbuf,
sc = device_get_softc(block->nmb_physdeviceobj->do_devext);
ifp = sc->ifp;
if (ifp->if_flags & IFF_DEBUG)
- device_printf (sc->ndis_dev, "status: %x\n", status);
- return;
+ device_printf(sc->ndis_dev, "status: %x\n", status);
}
static void
@@ -227,8 +225,7 @@ ndis_statusdone_func(adapter)
sc = device_get_softc(block->nmb_physdeviceobj->do_devext);
ifp = sc->ifp;
if (ifp->if_flags & IFF_DEBUG)
- device_printf (sc->ndis_dev, "status complete\n");
- return;
+ device_printf(sc->ndis_dev, "status complete\n");
}
static void
@@ -241,7 +238,6 @@ ndis_setdone_func(adapter, status)
block->nmb_setstat = status;
KeSetEvent(&block->nmb_setevent, IO_NO_INCREMENT, FALSE);
- return;
}
static void
@@ -254,7 +250,6 @@ ndis_getdone_func(adapter, status)
block->nmb_getstat = status;
KeSetEvent(&block->nmb_getevent, IO_NO_INCREMENT, FALSE);
- return;
}
static void
@@ -270,10 +265,8 @@ ndis_resetdone_func(ndis_handle adapter,
ifp = sc->ifp;
if (ifp->if_flags & IFF_DEBUG)
- device_printf (sc->ndis_dev, "reset done...\n");
+ device_printf(sc->ndis_dev, "reset done...\n");
KeSetEvent(&block->nmb_resetevent, IO_NO_INCREMENT, FALSE);
-
- return;
}
int
@@ -287,7 +280,7 @@ ndis_create_sysctls(arg)
struct sysctl_ctx_entry *e;
if (arg == NULL)
- return(EINVAL);
+ return (EINVAL);
sc = arg;
vals = sc->ndis_regvals;
@@ -367,7 +360,7 @@ ndis_create_sysctls(arg)
"Interrupt Number", buf, CTLFLAG_RD);
}
- return(0);
+ return (0);
}
int
@@ -388,7 +381,7 @@ ndis_add_sysctl(arg, key, desc, val, fla
if (cfg == NULL) {
printf("failed for %s\n", key);
- return(ENOMEM);
+ return (ENOMEM);
}
cfg->ndis_cfg.nc_cfgkey = strdup(key, M_DEVBUF);
@@ -415,7 +408,7 @@ ndis_add_sysctl(arg, key, desc, val, fla
cfg->ndis_cfg.nc_cfgdesc);
#endif
- return(0);
+ return (0);
}
/*
@@ -451,7 +444,7 @@ ndis_flush_sysctls(arg)
free(cfg, M_DEVBUF);
}
- return(0);
+ return (0);
}
static void
@@ -488,8 +481,6 @@ ndis_return(dobj, arg)
KeAcquireSpinLock(&block->nmb_returnlock, &irql);
}
KeReleaseSpinLock(&block->nmb_returnlock, irql);
-
- return;
}
void
@@ -522,8 +513,6 @@ ndis_return_packet(buf, arg)
IoQueueWorkItem(block->nmb_returnitem,
(io_workitem_func)kernndis_functbl[7].ipt_wrap,
WORKQUEUE_CRITICAL, block);
-
- return;
}
void
@@ -540,8 +529,6 @@ ndis_free_bufs(b0)
IoFreeMdl(b0);
b0 = next;
}
-
- return;
}
void
@@ -553,7 +540,6 @@ ndis_free_packet(p)
ndis_free_bufs(p->np_private.npp_head);
NdisFreePacket(p);
- return;
}
int
@@ -567,26 +553,18 @@ ndis_convert_res(arg)
device_t dev;
struct resource_list *brl;
struct resource_list_entry *brle;
-#if __FreeBSD_version < 600022
- struct resource_list brl_rev;
- struct resource_list_entry *n;
-#endif
int error = 0;
sc = arg;
block = sc->ndis_block;
dev = sc->ndis_dev;
-#if __FreeBSD_version < 600022
- SLIST_INIT(&brl_rev);
-#endif
-
rl = malloc(sizeof(ndis_resource_list) +
(sizeof(cm_partial_resource_desc) * (sc->ndis_rescnt - 1)),
M_DEVBUF, M_NOWAIT|M_ZERO);
if (rl == NULL)
- return(ENOMEM);
+ return (ENOMEM);
rl->cprl_version = 5;
rl->cprl_version = 1;
@@ -597,37 +575,7 @@ ndis_convert_res(arg)
if (brl != NULL) {
-#if __FreeBSD_version < 600022
- /*
- * We have a small problem. Some PCI devices have
- * multiple I/O ranges. Windows orders them starting
- * from lowest numbered BAR to highest. We discover
- * them in that order too, but insert them into a singly
- * linked list head first, which means when time comes
- * to traverse the list, we enumerate them in reverse
- * order. This screws up some drivers which expect the
- * BARs to be in ascending order so that they can choose
- * the "first" one as their register space. Unfortunately,
- * in order to fix this, we have to create our own
- * temporary list with the entries in reverse order.
- */
-
- SLIST_FOREACH(brle, brl, link) {
- n = malloc(sizeof(struct resource_list_entry),
- M_TEMP, M_NOWAIT);
- if (n == NULL) {
- error = ENOMEM;
- goto bad;
- }
- bcopy((char *)brle, (char *)n,
- sizeof(struct resource_list_entry));
- SLIST_INSERT_HEAD(&brl_rev, n, link);
- }
-
- SLIST_FOREACH(brle, &brl_rev, link) {
-#else
STAILQ_FOREACH(brle, brl, link) {
-#endif
switch (brle->type) {
case SYS_RES_IOPORT:
prd->cprd_type = CmResourceTypePort;
@@ -671,17 +619,7 @@ ndis_convert_res(arg)
block->nmb_rlist = rl;
-#if __FreeBSD_version < 600022
-bad:
-
- while (!SLIST_EMPTY(&brl_rev)) {
- n = SLIST_FIRST(&brl_rev);
- SLIST_REMOVE_HEAD(&brl_rev, link);
- free (n, M_TEMP);
- }
-#endif
-
- return(error);
+ return (error);
}
/*
@@ -711,7 +649,7 @@ ndis_ptom(m0, p)
int diff;
if (p == NULL || m0 == NULL)
- return(EINVAL);
+ return (EINVAL);
priv = &p->np_private;
buf = priv->npp_head;
@@ -729,7 +667,7 @@ ndis_ptom(m0, p)
if (m == NULL) {
m_freem(*m0);
*m0 = NULL;
- return(ENOBUFS);
+ return (ENOBUFS);
}
m->m_len = MmGetMdlByteCount(buf);
m->m_data = MmGetMdlVirtualAddress(buf);
@@ -765,7 +703,7 @@ ndis_ptom(m0, p)
}
(*m0)->m_pkthdr.len = totlen;
- return(0);
+ return (0);
}
/*
@@ -793,7 +731,7 @@ ndis_mtop(m0, p)
ndis_packet_private *priv;
if (p == NULL || *p == NULL || m0 == NULL)
- return(EINVAL);
+ return (EINVAL);
priv = &(*p)->np_private;
priv->npp_totlen = m0->m_pkthdr.len;
@@ -805,7 +743,7 @@ ndis_mtop(m0, p)
if (buf == NULL) {
ndis_free_packet(*p);
*p = NULL;
- return(ENOMEM);
+ return (ENOMEM);
}
MmBuildMdlForNonPagedPool(buf);
@@ -818,7 +756,7 @@ ndis_mtop(m0, p)
priv->npp_tail = buf;
- return(0);
+ return (0);
}
int
@@ -831,25 +769,25 @@ ndis_get_supported_oids(arg, oids, oidcn
ndis_oid *o;
if (arg == NULL || oids == NULL || oidcnt == NULL)
- return(EINVAL);
+ return (EINVAL);
len = 0;
ndis_get_info(arg, OID_GEN_SUPPORTED_LIST, NULL, &len);
o = malloc(len, M_DEVBUF, M_NOWAIT);
if (o == NULL)
- return(ENOMEM);
+ return (ENOMEM);
rval = ndis_get_info(arg, OID_GEN_SUPPORTED_LIST, o, &len);
if (rval) {
free(o, M_DEVBUF);
- return(rval);
+ return (rval);
}
*oids = o;
*oidcnt = len / 4;
- return(0);
+ return (0);
}
int
@@ -893,7 +831,7 @@ ndis_set_info(arg, oid, buf, buflen)
sc->ndis_block->nmb_devicectx == NULL) {
sc->ndis_block->nmb_pendingreq = NULL;
KeReleaseSpinLock(&sc->ndis_block->nmb_lock, irql);
- return(ENXIO);
+ return (ENXIO);
}
rval = MSCALL6(setfunc, adapter, oid, buf, *buflen,
@@ -917,19 +855,19 @@ ndis_set_info(arg, oid, buf, buflen)
*buflen = bytesneeded;
if (rval == NDIS_STATUS_INVALID_LENGTH)
- return(ENOSPC);
+ return (ENOSPC);
if (rval == NDIS_STATUS_INVALID_OID)
- return(EINVAL);
+ return (EINVAL);
if (rval == NDIS_STATUS_NOT_SUPPORTED ||
rval == NDIS_STATUS_NOT_ACCEPTED)
- return(ENOTSUP);
+ return (ENOTSUP);
if (rval != NDIS_STATUS_SUCCESS)
- return(ENODEV);
+ return (ENODEV);
- return(0);
+ return (0);
}
typedef void (*ndis_senddone_func)(ndis_handle, ndis_packet *, ndis_status);
@@ -951,7 +889,7 @@ ndis_send_packets(arg, packets, cnt)
sc = arg;
adapter = sc->ndis_block->nmb_miniportadapterctx;
if (adapter == NULL)
- return(ENXIO);
+ return (ENXIO);
sendfunc = sc->ndis_chars->nmc_sendmulti_func;
senddonefunc = sc->ndis_block->nmb_senddone_func;
@@ -976,7 +914,7 @@ ndis_send_packets(arg, packets, cnt)
if (NDIS_SERIALIZED(sc->ndis_block))
KeReleaseSpinLock(&sc->ndis_block->nmb_lock, irql);
- return(0);
+ return (0);
}
int
@@ -994,7 +932,7 @@ ndis_send_packet(arg, packet)
sc = arg;
adapter = sc->ndis_block->nmb_miniportadapterctx;
if (adapter == NULL)
- return(ENXIO);
+ return (ENXIO);
sendfunc = sc->ndis_chars->nmc_sendsingle_func;
senddonefunc = sc->ndis_block->nmb_senddone_func;
@@ -1006,7 +944,7 @@ ndis_send_packet(arg, packet)
if (status == NDIS_STATUS_PENDING) {
if (NDIS_SERIALIZED(sc->ndis_block))
KeReleaseSpinLock(&sc->ndis_block->nmb_lock, irql);
- return(0);
+ return (0);
}
MSCALL3(senddonefunc, sc->ndis_block, packet, status);
@@ -1014,7 +952,7 @@ ndis_send_packet(arg, packet)
if (NDIS_SERIALIZED(sc->ndis_block))
KeReleaseSpinLock(&sc->ndis_block->nmb_lock, irql);
- return(0);
+ return (0);
}
int
@@ -1030,18 +968,18 @@ ndis_init_dma(arg)
M_DEVBUF, M_NOWAIT|M_ZERO);
if (sc->ndis_tmaps == NULL)
- return(ENOMEM);
+ return (ENOMEM);
for (i = 0; i < sc->ndis_maxpkts; i++) {
error = bus_dmamap_create(sc->ndis_ttag, 0,
&sc->ndis_tmaps[i]);
if (error) {
free(sc->ndis_tmaps, M_DEVBUF);
- return(ENODEV);
+ return (ENODEV);
}
}
- return(0);
+ return (0);
}
int
@@ -1070,7 +1008,7 @@ ndis_destroy_dma(arg)
bus_dma_tag_destroy(sc->ndis_ttag);
- return(0);
+ return (0);
}
int
@@ -1093,7 +1031,7 @@ ndis_reset_nic(arg)
if (adapter == NULL || resetfunc == NULL ||
sc->ndis_block->nmb_devicectx == NULL) {
NDIS_UNLOCK(sc);
- return(EIO);
+ return (EIO);
}
NDIS_UNLOCK(sc);
@@ -1112,7 +1050,7 @@ ndis_reset_nic(arg)
KeWaitForSingleObject(&sc->ndis_block->nmb_resetevent,
0, 0, FALSE, NULL);
- return(0);
+ return (0);
}
int
@@ -1149,7 +1087,7 @@ ndis_halt_nic(arg)
adapter = sc->ndis_block->nmb_miniportadapterctx;
if (adapter == NULL) {
NDIS_UNLOCK(sc);
- return(EIO);
+ return (EIO);
}
sc->ndis_block->nmb_devicectx = NULL;
@@ -1169,7 +1107,7 @@ ndis_halt_nic(arg)
sc->ndis_block->nmb_miniportadapterctx = NULL;
NDIS_UNLOCK(sc);
- return(0);
+ return (0);
}
int
@@ -1186,7 +1124,7 @@ ndis_shutdown_nic(arg)
shutdownfunc = sc->ndis_chars->nmc_shutdown_handler;
NDIS_UNLOCK(sc);
if (adapter == NULL || shutdownfunc == NULL)
- return(EIO);
+ return (EIO);
if (sc->ndis_chars->nmc_rsvd0 == NULL)
MSCALL1(shutdownfunc, adapter);
@@ -1195,7 +1133,7 @@ ndis_shutdown_nic(arg)
TAILQ_REMOVE(&ndis_devhead, sc->ndis_block, link);
- return(0);
+ return (0);
}
int
@@ -1215,7 +1153,7 @@ ndis_pnpevent_nic(arg, type)
pnpeventfunc = sc->ndis_chars->nmc_pnpevent_handler;
NDIS_UNLOCK(sc);
if (adapter == NULL || pnpeventfunc == NULL)
- return(EIO);
+ return (EIO);
if (sc->ndis_chars->nmc_rsvd0 == NULL)
MSCALL4(pnpeventfunc, adapter, type, NULL, 0);
@@ -1237,7 +1175,7 @@ ndis_init_nic(arg)
uint32_t chosenmedium, i;
if (arg == NULL)
- return(EINVAL);
+ return (EINVAL);
sc = arg;
NDIS_LOCK(sc);
@@ -1262,7 +1200,7 @@ ndis_init_nic(arg)
NDIS_LOCK(sc);
sc->ndis_block->nmb_miniportadapterctx = NULL;
NDIS_UNLOCK(sc);
- return(ENXIO);
+ return (status);
}
/*
@@ -1281,7 +1219,7 @@ ndis_init_nic(arg)
sc->ndis_block->nmb_devicectx = sc;
NDIS_UNLOCK(sc);
- return(0);
+ return (0);
}
static void
@@ -1305,8 +1243,6 @@ ndis_intrsetup(dpc, dobj, ip, sc)
if (KeInsertQueueDpc(&intr->ni_dpc, NULL, NULL) == TRUE)
intr->ni_dpccnt++;
KeReleaseSpinLockFromDpcLevel(&intr->ni_dpccountlock);
-
- return;
}
int
@@ -1343,7 +1279,7 @@ ndis_get_info(arg, oid, buf, buflen)
sc->ndis_block->nmb_devicectx == NULL) {
sc->ndis_block->nmb_pendingreq = NULL;
KeReleaseSpinLock(&sc->ndis_block->nmb_lock, irql);
- return(ENXIO);
+ return (ENXIO);
}
rval = MSCALL6(queryfunc, adapter, oid, buf, *buflen,
@@ -1370,19 +1306,19 @@ ndis_get_info(arg, oid, buf, buflen)
if (rval == NDIS_STATUS_INVALID_LENGTH ||
rval == NDIS_STATUS_BUFFER_TOO_SHORT)
- return(ENOSPC);
+ return (ENOSPC);
if (rval == NDIS_STATUS_INVALID_OID)
- return(EINVAL);
+ return (EINVAL);
if (rval == NDIS_STATUS_NOT_SUPPORTED ||
rval == NDIS_STATUS_NOT_ACCEPTED)
- return(ENOTSUP);
+ return (ENOTSUP);
if (rval != NDIS_STATUS_SUCCESS)
- return(ENODEV);
+ return (ENODEV);
- return(0);
+ return (0);
}
uint32_t
@@ -1403,14 +1339,14 @@ NdisAddDevice(drv, pdo)
INTR_TYPE_NET | INTR_MPSAFE,
NULL, ntoskrnl_intr, NULL, &sc->ndis_intrhand);
if (error)
- return(NDIS_STATUS_FAILURE);
+ return (NDIS_STATUS_FAILURE);
}
status = IoCreateDevice(drv, sizeof(ndis_miniport_block), NULL,
FILE_DEVICE_UNKNOWN, 0, FALSE, &fdo);
if (status != STATUS_SUCCESS)
- return(status);
+ return (status);
block = fdo->do_devext;
@@ -1446,7 +1382,7 @@ NdisAddDevice(drv, pdo)
if (status != NDIS_STATUS_SUCCESS) {
IoDetachDevice(block->nmb_nextdeviceobj);
IoDeleteDevice(fdo);
- return(status);
+ return (status);
}
InitializeListHead((&block->nmb_packetlist));
}
@@ -1498,5 +1434,5 @@ ndis_unload_driver(arg)
IoDetachDevice(sc->ndis_block->nmb_nextdeviceobj);
IoDeleteDevice(fdo);
- return(0);
+ return (0);
}
Modified: head/sys/compat/ndis/kern_windrv.c
==============================================================================
--- head/sys/compat/ndis/kern_windrv.c Mon Nov 2 09:56:46 2009 (r198785)
+++ head/sys/compat/ndis/kern_windrv.c Mon Nov 2 11:07:42 2009 (r198786)
@@ -123,7 +123,7 @@ windrv_libinit(void)
panic("failed to allocate thread info blocks");
smp_rendezvous(NULL, x86_newldt, NULL, NULL);
#endif
- return(0);
+ return (0);
}
int
@@ -148,7 +148,7 @@ windrv_libfini(void)
smp_rendezvous(NULL, x86_oldldt, NULL, NULL);
ExFreePool(my_tids);
#endif
- return(0);
+ return (0);
}
/*
@@ -172,7 +172,7 @@ windrv_lookup(img, name)
if (name != NULL) {
RtlInitAnsiString(&as, name);
if (RtlAnsiStringToUnicodeString(&us, &as, TRUE))
- return(NULL);
+ return (NULL);
}
mtx_lock(&drvdb_mtx);
@@ -183,7 +183,7 @@ windrv_lookup(img, name)
mtx_unlock(&drvdb_mtx);
if (name != NULL)
ExFreePool(us.us_buf);
- return(d->windrv_object);
+ return (d->windrv_object);
}
}
mtx_unlock(&drvdb_mtx);
@@ -191,7 +191,7 @@ windrv_lookup(img, name)
if (name != NULL)
RtlFreeUnicodeString(&us);
- return(NULL);
+ return (NULL);
}
struct drvdb_ent *
@@ -209,12 +209,12 @@ windrv_match(matchfunc, ctx)
match = matchfunc(d->windrv_bustype, d->windrv_devlist, ctx);
if (match == TRUE) {
mtx_unlock(&drvdb_mtx);
- return(d);
+ return (d);
}
}
mtx_unlock(&drvdb_mtx);
- return(NULL);
+ return (NULL);
}
/*
@@ -283,7 +283,7 @@ windrv_unload(mod, img, len)
return (ENOENT);
if (drv == NULL)
- return(ENOENT);
+ return (ENOENT);
/*
* Destroy any custom extensions that may have been added.
@@ -306,7 +306,7 @@ windrv_unload(mod, img, len)
/* Free our DB handle */
free(r, M_DEVBUF);
- return(0);
+ return (0);
}
#define WINDRV_LOADED htonl(0x42534F44)
@@ -345,28 +345,28 @@ windrv_load(mod, img, len, bustype, devl
/* Perform text relocation */
if (pe_relocate(img))
- return(ENOEXEC);
+ return (ENOEXEC);
/* Dynamically link the NDIS.SYS routines -- required. */
if (pe_patch_imports(img, "NDIS", ndis_functbl))
- return(ENOEXEC);
+ return (ENOEXEC);
/* Dynamically link the HAL.dll routines -- optional. */
if (pe_get_import_descriptor(img, &imp_desc, "HAL") == 0) {
if (pe_patch_imports(img, "HAL", hal_functbl))
- return(ENOEXEC);
+ return (ENOEXEC);
}
/* Dynamically link ntoskrnl.exe -- optional. */
if (pe_get_import_descriptor(img, &imp_desc, "ntoskrnl") == 0) {
if (pe_patch_imports(img, "ntoskrnl", ntoskrnl_functbl))
- return(ENOEXEC);
+ return (ENOEXEC);
}
/* Dynamically link USBD.SYS -- optional */
if (pe_get_import_descriptor(img, &imp_desc, "USBD") == 0) {
if (pe_patch_imports(img, "USBD", usbd_functbl))
- return(ENOEXEC);
+ return (ENOEXEC);
}
*ptr = WINDRV_LOADED;
@@ -398,7 +398,7 @@ skipreloc:
if (drv->dro_driverext == NULL) {
free(new, M_DEVBUF);
free(drv, M_DEVBUF);
- return(ENOMEM);
+ return (ENOMEM);
}
InitializeListHead((&drv->dro_driverext->dre_usrext));
@@ -410,7 +410,7 @@ skipreloc:
if (RtlAnsiStringToUnicodeString(&drv->dro_drivername, &as, TRUE)) {
free(new, M_DEVBUF);
free(drv, M_DEVBUF);
- return(ENOMEM);
+ return (ENOMEM);
}
new->windrv_object = drv;
@@ -426,7 +426,7 @@ skipreloc:
RtlFreeUnicodeString(&drv->dro_drivername);
free(drv, M_DEVBUF);
free(new, M_DEVBUF);
- return(ENODEV);
+ return (ENODEV);
}
mtx_lock(&drvdb_mtx);
@@ -463,7 +463,7 @@ windrv_create_pdo(drv, bsddev)
dev->do_devext = bsddev;
- return(STATUS_SUCCESS);
+ return (STATUS_SUCCESS);
}
void
@@ -482,8 +482,6 @@ windrv_destroy_pdo(drv, bsddev)
mtx_lock(&drvdb_mtx);
IoDeleteDevice(pdo);
mtx_unlock(&drvdb_mtx);
-
- return;
}
/*
@@ -503,13 +501,13 @@ windrv_find_pdo(drv, bsddev)
while (pdo != NULL) {
if (pdo->do_devext == bsddev) {
mtx_unlock(&drvdb_mtx);
- return(pdo);
+ return (pdo);
}
pdo = pdo->do_nextdev;
}
mtx_unlock(&drvdb_mtx);
- return(NULL);
+ return (NULL);
}
/*
@@ -533,7 +531,7 @@ windrv_bus_attach(drv, name)
if (RtlAnsiStringToUnicodeString(&drv->dro_drivername, &as, TRUE))
{
free(new, M_DEVBUF);
- return(ENOMEM);
+ return (ENOMEM);
}
/*
@@ -550,7 +548,7 @@ windrv_bus_attach(drv, name)
STAILQ_INSERT_HEAD(&drvdb_head, new, link);
mtx_unlock(&drvdb_mtx);
- return(0);
+ return (0);
}
#ifdef __amd64__
@@ -578,7 +576,7 @@ windrv_wrap(func, wrap, argcnt, ftype)
p = malloc((wrapend - wrapstart), M_DEVBUF, M_NOWAIT);
if (p == NULL)
- return(ENOMEM);
+ return (ENOMEM);
/* Copy over the code. */
@@ -591,7 +589,7 @@ windrv_wrap(func, wrap, argcnt, ftype)
*wrap = p;
- return(0);
+ return (0);
}
#endif /* __amd64__ */
@@ -695,8 +693,6 @@ ctxsw_utow(void)
x86_critical_exit();
/* Now entering Windows land, population: you. */
-
- return;
}
/*
@@ -722,7 +718,6 @@ ctxsw_wtou(void)
if (t->tid_cpu != curthread->td_oncpu)
panic("ctxsw GOT MOVED TO OTHER CPU!");
#endif
- return;
}
static int windrv_wrap_stdcall(funcptr, funcptr *, int);
@@ -754,7 +749,7 @@ windrv_wrap_fastcall(func, wrap, argcnt)
p = malloc((wrapend - wrapstart), M_DEVBUF, M_NOWAIT);
if (p == NULL)
- return(ENOMEM);
+ return (ENOMEM);
/* Copy over the code. */
@@ -774,7 +769,7 @@ windrv_wrap_fastcall(func, wrap, argcnt)
*wrap = p;
- return(0);
+ return (0);
}
extern void x86_stdcall_wrap(void);
@@ -802,7 +797,7 @@ windrv_wrap_stdcall(func, wrap, argcnt)
p = malloc((wrapend - wrapstart), M_DEVBUF, M_NOWAIT);
if (p == NULL)
- return(ENOMEM);
+ return (ENOMEM);
/* Copy over the code. */
@@ -818,7 +813,7 @@ windrv_wrap_stdcall(func, wrap, argcnt)
*wrap = p;
- return(0);
+ return (0);
}
extern void x86_regparm_wrap(void);
@@ -842,7 +837,7 @@ windrv_wrap_regparm(func, wrap)
p = malloc((wrapend - wrapstart), M_DEVBUF, M_NOWAIT);
if (p == NULL)
- return(ENOMEM);
+ return (ENOMEM);
/* Copy over the code. */
@@ -855,7 +850,7 @@ windrv_wrap_regparm(func, wrap)
*wrap = p;
- return(0);
+ return (0);
}
int
@@ -867,18 +862,18 @@ windrv_wrap(func, wrap, argcnt, ftype)
{
switch(ftype) {
case WINDRV_WRAP_FASTCALL:
- return(windrv_wrap_fastcall(func, wrap, argcnt));
+ return (windrv_wrap_fastcall(func, wrap, argcnt));
case WINDRV_WRAP_STDCALL:
- return(windrv_wrap_stdcall(func, wrap, argcnt));
+ return (windrv_wrap_stdcall(func, wrap, argcnt));
case WINDRV_WRAP_REGPARM:
- return(windrv_wrap_regparm(func, wrap));
+ return (windrv_wrap_regparm(func, wrap));
case WINDRV_WRAP_CDECL:
- return(windrv_wrap_stdcall(func, wrap, 0));
+ return (windrv_wrap_stdcall(func, wrap, 0));
default:
break;
}
- return(EINVAL);
+ return (EINVAL);
}
static void
@@ -909,8 +904,6 @@ x86_oldldt(dummy)
x86_setldt(>able, ltable);
mtx_unlock_spin(&dt_lock);
-
- return;
}
static void
@@ -959,8 +952,6 @@ x86_newldt(dummy)
mtx_unlock_spin(&dt_lock);
/* Whew. */
-
- return;
}
#endif /* __i386__ */
@@ -971,5 +962,5 @@ windrv_unwrap(func)
{
free(func, M_DEVBUF);
- return(0);
+ return (0);
}
Modified: head/sys/compat/ndis/subr_hal.c
==============================================================================
--- head/sys/compat/ndis/subr_hal.c Mon Nov 2 09:56:46 2009 (r198785)
+++ head/sys/compat/ndis/subr_hal.c Mon Nov 2 11:07:42 2009 (r198786)
@@ -102,8 +102,7 @@ hal_libinit()
patch++;
}
-
- return(0);
+ return (0);
}
int
@@ -121,7 +120,7 @@ hal_libfini()
patch++;
}
- return(0);
+ return (0);
}
static void
@@ -129,7 +128,6 @@ KeStallExecutionProcessor(usecs)
uint32_t usecs;
{
DELAY(usecs);
- return;
}
static void
@@ -138,21 +136,18 @@ WRITE_PORT_ULONG(port, val)
uint32_t val;
{
bus_space_write_4(NDIS_BUS_SPACE_IO, 0x0, (bus_size_t)port, val);
- return;
}
static void
WRITE_PORT_USHORT(uint16_t *port, uint16_t val)
{
bus_space_write_2(NDIS_BUS_SPACE_IO, 0x0, (bus_size_t)port, val);
- return;
}
static void
WRITE_PORT_UCHAR(uint8_t *port, uint8_t val)
{
bus_space_write_1(NDIS_BUS_SPACE_IO, 0x0, (bus_size_t)port, val);
- return;
}
static void
@@ -163,7 +158,6 @@ WRITE_PORT_BUFFER_ULONG(port, val, cnt)
{
bus_space_write_multi_4(NDIS_BUS_SPACE_IO, 0x0,
(bus_size_t)port, val, cnt);
- return;
}
static void
@@ -174,7 +168,6 @@ WRITE_PORT_BUFFER_USHORT(port, val, cnt)
{
bus_space_write_multi_2(NDIS_BUS_SPACE_IO, 0x0,
(bus_size_t)port, val, cnt);
- return;
}
static void
@@ -185,28 +178,27 @@ WRITE_PORT_BUFFER_UCHAR(port, val, cnt)
{
bus_space_write_multi_1(NDIS_BUS_SPACE_IO, 0x0,
(bus_size_t)port, val, cnt);
- return;
}
static uint16_t
READ_PORT_USHORT(port)
uint16_t *port;
*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***
From remko at FreeBSD.org Mon Nov 2 12:03:05 2009
From: remko at FreeBSD.org (Remko Lodder)
Date: Mon Nov 2 12:03:15 2009
Subject: svn commit: r198787 - head/share/man/man5
Message-ID: <200911021203.nA2C34EL056037@svn.freebsd.org>
Author: remko
Date: Mon Nov 2 12:03:04 2009
New Revision: 198787
URL: http://svn.freebsd.org/changeset/base/198787
Log:
Document the WWWSUPFILE variable.
PR: 137723
Submitted by: Sofian Brabez
Approved by: imp (mentor, implicit)
MFC after: 3 days
Facilitated by: Snow B.V.
Modified:
head/share/man/man5/make.conf.5
Modified: head/share/man/man5/make.conf.5
==============================================================================
--- head/share/man/man5/make.conf.5 Mon Nov 2 11:07:42 2009 (r198786)
+++ head/share/man/man5/make.conf.5 Mon Nov 2 12:03:04 2009 (r198787)
@@ -318,6 +318,14 @@ Set this to use
.Xr cvsup 1
to update your ports with
.Dq Li "make update" .
+.It Va WWWSUPFILE
+.Pq Vt str
+The www
+.Ar supfile
+to use when doing a
+.Dq Li "make update"
+This defaults to
+.Pa /usr/share/examples/cvsup/www\-supfile .
.El
.Ss "BUILDING THE KERNEL"
The following list provides a name and short description for variables
From brueffer at FreeBSD.org Mon Nov 2 12:35:39 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Mon Nov 2 12:35:52 2009
Subject: svn commit: r198788 - in head: bin/getfacl lib/libc/gen lib/libpmc
share/man/man4 share/man/man5 share/man/man7 usr.bin/tail
usr.sbin/i2c usr.sbin/nfsd usr.sbin/wake
Message-ID: <200911021235.nA2CZc1R056811@svn.freebsd.org>
Author: brueffer
Date: Mon Nov 2 12:35:38 2009
New Revision: 198788
URL: http://svn.freebsd.org/changeset/base/198788
Log:
Use our canonical .Dd format.
Submitted by: Ulrich Spoerlein
Modified:
head/bin/getfacl/getfacl.1
head/lib/libc/gen/posix_spawn.3
head/lib/libc/gen/posix_spawn_file_actions_addopen.3
head/lib/libc/gen/posix_spawn_file_actions_init.3
head/lib/libc/gen/posix_spawnattr_getflags.3
head/lib/libc/gen/posix_spawnattr_getpgroup.3
head/lib/libc/gen/posix_spawnattr_getschedparam.3
head/lib/libc/gen/posix_spawnattr_getschedpolicy.3
head/lib/libc/gen/posix_spawnattr_getsigdefault.3
head/lib/libc/gen/posix_spawnattr_getsigmask.3
head/lib/libc/gen/posix_spawnattr_init.3
head/lib/libpmc/pmc_attach.3
head/share/man/man4/tty.4
head/share/man/man5/ar.5
head/share/man/man5/msdosfs.5
head/share/man/man7/adding_user.7
head/usr.bin/tail/tail.1
head/usr.sbin/i2c/i2c.8
head/usr.sbin/nfsd/stablerestart.5
head/usr.sbin/wake/wake.8
Modified: head/bin/getfacl/getfacl.1
==============================================================================
--- head/bin/getfacl/getfacl.1 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/bin/getfacl/getfacl.1 Mon Nov 2 12:35:38 2009 (r198788)
@@ -30,7 +30,7 @@
.\" Developed by the TrustedBSD Project.
.\" Support for POSIX.1e access control lists.
.\"
-.Dd September 04, 2009
+.Dd September 4, 2009
.Dt GETFACL 1
.Os
.Sh NAME
Modified: head/lib/libc/gen/posix_spawn.3
==============================================================================
--- head/lib/libc/gen/posix_spawn.3 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/lib/libc/gen/posix_spawn.3 Mon Nov 2 12:35:38 2009 (r198788)
@@ -34,7 +34,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd Mar 24, 2008
+.Dd March 24, 2008
.Dt POSIX_SPAWN 3
.Os
.Sh NAME
Modified: head/lib/libc/gen/posix_spawn_file_actions_addopen.3
==============================================================================
--- head/lib/libc/gen/posix_spawn_file_actions_addopen.3 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/lib/libc/gen/posix_spawn_file_actions_addopen.3 Mon Nov 2 12:35:38 2009 (r198788)
@@ -34,7 +34,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd Mar 24, 2008
+.Dd March 24, 2008
.Dt POSIX_SPAWN_FILE_ACTIONS_ADDOPEN 3
.Os
.Sh NAME
Modified: head/lib/libc/gen/posix_spawn_file_actions_init.3
==============================================================================
--- head/lib/libc/gen/posix_spawn_file_actions_init.3 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/lib/libc/gen/posix_spawn_file_actions_init.3 Mon Nov 2 12:35:38 2009 (r198788)
@@ -34,7 +34,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd Mar 24, 2008
+.Dd March 24, 2008
.Dt POSIX_SPAWN_FILE_ACTIONS_INIT 3
.Os
.Sh NAME
Modified: head/lib/libc/gen/posix_spawnattr_getflags.3
==============================================================================
--- head/lib/libc/gen/posix_spawnattr_getflags.3 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/lib/libc/gen/posix_spawnattr_getflags.3 Mon Nov 2 12:35:38 2009 (r198788)
@@ -34,7 +34,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd Mar 24, 2008
+.Dd March 24, 2008
.Dt POSIX_SPAWNATTR_GETFLAGS 3
.Os
.Sh NAME
Modified: head/lib/libc/gen/posix_spawnattr_getpgroup.3
==============================================================================
--- head/lib/libc/gen/posix_spawnattr_getpgroup.3 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/lib/libc/gen/posix_spawnattr_getpgroup.3 Mon Nov 2 12:35:38 2009 (r198788)
@@ -34,7 +34,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd Mar 24, 2008
+.Dd March 24, 2008
.Dt POSIX_SPAWNATTR_GETPGROUP 3
.Os
.Sh NAME
Modified: head/lib/libc/gen/posix_spawnattr_getschedparam.3
==============================================================================
--- head/lib/libc/gen/posix_spawnattr_getschedparam.3 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/lib/libc/gen/posix_spawnattr_getschedparam.3 Mon Nov 2 12:35:38 2009 (r198788)
@@ -34,7 +34,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd Mar 24, 2008
+.Dd March 24, 2008
.Dt POSIX_SPAWNATTR_GETSCHEDPARAM 3
.Os
.Sh NAME
Modified: head/lib/libc/gen/posix_spawnattr_getschedpolicy.3
==============================================================================
--- head/lib/libc/gen/posix_spawnattr_getschedpolicy.3 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/lib/libc/gen/posix_spawnattr_getschedpolicy.3 Mon Nov 2 12:35:38 2009 (r198788)
@@ -34,7 +34,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd Mar 24, 2008
+.Dd March 24, 2008
.Dt POSIX_SPAWNATTR_GETSCHEDPOLICY 3
.Os
.Sh NAME
Modified: head/lib/libc/gen/posix_spawnattr_getsigdefault.3
==============================================================================
--- head/lib/libc/gen/posix_spawnattr_getsigdefault.3 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/lib/libc/gen/posix_spawnattr_getsigdefault.3 Mon Nov 2 12:35:38 2009 (r198788)
@@ -34,7 +34,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd Mar 24, 2008
+.Dd March 24, 2008
.Dt POSIX_SPAWNATTR_GETSIGDEFAULT 3
.Os
.Sh NAME
Modified: head/lib/libc/gen/posix_spawnattr_getsigmask.3
==============================================================================
--- head/lib/libc/gen/posix_spawnattr_getsigmask.3 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/lib/libc/gen/posix_spawnattr_getsigmask.3 Mon Nov 2 12:35:38 2009 (r198788)
@@ -34,7 +34,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd Mar 24, 2008
+.Dd March 24, 2008
.Dt POSIX_SPAWNATTR_GETSIGMASK 3
.Os
.Sh NAME
Modified: head/lib/libc/gen/posix_spawnattr_init.3
==============================================================================
--- head/lib/libc/gen/posix_spawnattr_init.3 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/lib/libc/gen/posix_spawnattr_init.3 Mon Nov 2 12:35:38 2009 (r198788)
@@ -34,7 +34,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd Mar 24, 2008
+.Dd March 24, 2008
.Dt POSIX_SPAWNATTR_INIT 3
.Os
.Sh NAME
Modified: head/lib/libpmc/pmc_attach.3
==============================================================================
--- head/lib/libpmc/pmc_attach.3 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/lib/libpmc/pmc_attach.3 Mon Nov 2 12:35:38 2009 (r198788)
@@ -23,7 +23,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd November 25 2007
+.Dd November 25, 2007
.Os
.Dt PMC_ATTACH 3
.Sh NAME
Modified: head/share/man/man4/tty.4
==============================================================================
--- head/share/man/man4/tty.4 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/share/man/man4/tty.4 Mon Nov 2 12:35:38 2009 (r198788)
@@ -32,7 +32,7 @@
.\" @(#)tty.4 8.3 (Berkeley) 4/19/94
.\" $FreeBSD$
.\"
-.Dd Jun 27, 2007
+.Dd June 27, 2007
.Dt TTY 4
.Os
.Sh NAME
Modified: head/share/man/man5/ar.5
==============================================================================
--- head/share/man/man5/ar.5 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/share/man/man5/ar.5 Mon Nov 2 12:35:38 2009 (r198788)
@@ -23,7 +23,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd September 07, 2007
+.Dd September 7, 2007
.Os
.Dt AR 5
.Sh NAME
Modified: head/share/man/man5/msdosfs.5
==============================================================================
--- head/share/man/man5/msdosfs.5 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/share/man/man5/msdosfs.5 Mon Nov 2 12:35:38 2009 (r198788)
@@ -2,7 +2,7 @@
.\" Written by Tom Rhodes
.\" This file is in the public domain.
.\"
-.Dd Aug 22, 2007
+.Dd August 22, 2007
.Dt MSDOSFS 5
.Os
.Sh NAME
Modified: head/share/man/man7/adding_user.7
==============================================================================
--- head/share/man/man7/adding_user.7 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/share/man/man7/adding_user.7 Mon Nov 2 12:35:38 2009 (r198788)
@@ -32,7 +32,7 @@
.\" @(#)adduser.8 8.1 (Berkeley) 6/5/93
.\" $FreeBSD$
.\"
-.Dd Jan 30, 2009
+.Dd January 30, 2009
.Dt ADDING_USER 8
.Os
.Sh NAME
Modified: head/usr.bin/tail/tail.1
==============================================================================
--- head/usr.bin/tail/tail.1 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/usr.bin/tail/tail.1 Mon Nov 2 12:35:38 2009 (r198788)
@@ -35,7 +35,7 @@
.\" @(#)tail.1 8.1 (Berkeley) 6/6/93
.\" $FreeBSD$
.\"
-.Dd June 05, 2009
+.Dd June 5, 2009
.Dt TAIL 1
.Os
.Sh NAME
Modified: head/usr.sbin/i2c/i2c.8
==============================================================================
--- head/usr.sbin/i2c/i2c.8 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/usr.sbin/i2c/i2c.8 Mon Nov 2 12:35:38 2009 (r198788)
@@ -26,7 +26,7 @@
.\" $FreeBSD$
.\"
-.Dd Jan 23, 2009
+.Dd January 23, 2009
.Dt I2C 8
.Os
.Sh NAME
Modified: head/usr.sbin/nfsd/stablerestart.5
==============================================================================
--- head/usr.sbin/nfsd/stablerestart.5 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/usr.sbin/nfsd/stablerestart.5 Mon Nov 2 12:35:38 2009 (r198788)
@@ -24,7 +24,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd Sept 7, 2007
+.Dd September 7, 2007
.Dt STABLERESTART 5
.Os
.Sh NAME
Modified: head/usr.sbin/wake/wake.8
==============================================================================
--- head/usr.sbin/wake/wake.8 Mon Nov 2 12:03:04 2009 (r198787)
+++ head/usr.sbin/wake/wake.8 Mon Nov 2 12:35:38 2009 (r198788)
@@ -15,7 +15,7 @@
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd June 27 2009
+.Dd June 27, 2009
.Dt WAKE 8
.Os
.Sh NAME
From rwatson at FreeBSD.org Mon Nov 2 15:00:40 2009
From: rwatson at FreeBSD.org (Robert Watson)
Date: Mon Nov 2 15:00:46 2009
Subject: svn commit: r198781 - head/lib/libc/sys
In-Reply-To: <200911020721.nA27LDq1048764@svn.freebsd.org>
References: <200911020721.nA27LDq1048764@svn.freebsd.org>
Message-ID:
On Mon, 2 Nov 2009, Colin Percival wrote:
> Attempt to reduce accidental foot-shooting by pointing out that
> accept(2)ed sockets do not necessarily inherit O_NONBLOCK from
> listening sockets on non-FreeBSD platforms.
I wonder how much trouble we should go to to document bugs in other systems as
non-portabilities for features that work in our system. This bug in Linux was
brought to my attention recently:
SO_RCVLOWAT and SO_SNDLOWAT
Specify the minimum number of bytes in the buffer until the
socket layer will pass the data to the protocol (SO_SNDLOWAT) or
the user on receiving (SO_RCVLOWAT). These two values are ini?
tialized to 1. SO_SNDLOWAT is not changeable on Linux (setsock?
opt(2) fails with the error ENOPROTOOPT). SO_RCVLOWAT is
changeable only since Linux 2.4. The select(2) and poll(2) sys?
tem calls currently do not respect the SO_RCVLOWAT setting on
Linux, and mark a socket readable when even a single byte of
data is available. A subsequent read from the socket will block
until SO_RCVLOWAT bytes are available.
I think a more general caution for accept(2) might instead be:
BUGS
The inheritence of socket options from a listen socket to a newly
accepted socket is inconsistent across protocols, and non-portable.
Robert
>
> Feet shot: cperciva
> MFC after: 1 month
>
> Modified:
> head/lib/libc/sys/accept.2
>
> Modified: head/lib/libc/sys/accept.2
> ==============================================================================
> --- head/lib/libc/sys/accept.2 Mon Nov 2 06:36:54 2009 (r198780)
> +++ head/lib/libc/sys/accept.2 Mon Nov 2 07:21:13 2009 (r198781)
> @@ -126,6 +126,10 @@ new socket.
> For some applications, performance may be enhanced by using an
> .Xr accept_filter 9
> to pre-process incoming connections.
> +.Pp
> +Portable programs should not rely on the
> +.Dv O_NONBLOCK
> +property being inherited.
> .Sh RETURN VALUES
> The call returns \-1 on error.
> If it succeeds, it returns a non-negative
>
From rnoland at FreeBSD.org Mon Nov 2 15:09:04 2009
From: rnoland at FreeBSD.org (Robert Noland)
Date: Mon Nov 2 15:09:11 2009
Subject: svn commit: r198781 - head/lib/libc/sys
In-Reply-To:
References: <200911020721.nA27LDq1048764@svn.freebsd.org>
Message-ID: <1257174533.73292.10.camel@balrog.2hip.net>
On Mon, 2009-11-02 at 15:00 +0000, Robert Watson wrote:
> On Mon, 2 Nov 2009, Colin Percival wrote:
>
> > Attempt to reduce accidental foot-shooting by pointing out that
> > accept(2)ed sockets do not necessarily inherit O_NONBLOCK from
> > listening sockets on non-FreeBSD platforms.
>
> I wonder how much trouble we should go to to document bugs in other systems as
> non-portabilities for features that work in our system. This bug in Linux was
> brought to my attention recently:
>
> SO_RCVLOWAT and SO_SNDLOWAT
> Specify the minimum number of bytes in the buffer until the
> socket layer will pass the data to the protocol (SO_SNDLOWAT) or
> the user on receiving (SO_RCVLOWAT). These two values are ini?
> tialized to 1. SO_SNDLOWAT is not changeable on Linux (setsock?
> opt(2) fails with the error ENOPROTOOPT). SO_RCVLOWAT is
> changeable only since Linux 2.4. The select(2) and poll(2) sys?
> tem calls currently do not respect the SO_RCVLOWAT setting on
> Linux, and mark a socket readable when even a single byte of
> data is available. A subsequent read from the socket will block
> until SO_RCVLOWAT bytes are available.
>
> I think a more general caution for accept(2) might instead be:
>
> BUGS
> The inheritence of socket options from a listen socket to a newly
> accepted socket is inconsistent across protocols, and non-portable.
I don't think we have any business documenting what linux does or does
not do. As much as I would hate to see someone wasting time finding
this linux bug, we should only document our own behavior. Hopefully we
at least have a hope of keeping that information accurate.
robert.
> Robert
>
> >
> > Feet shot: cperciva
> > MFC after: 1 month
> >
> > Modified:
> > head/lib/libc/sys/accept.2
> >
> > Modified: head/lib/libc/sys/accept.2
> > ==============================================================================
> > --- head/lib/libc/sys/accept.2 Mon Nov 2 06:36:54 2009 (r198780)
> > +++ head/lib/libc/sys/accept.2 Mon Nov 2 07:21:13 2009 (r198781)
> > @@ -126,6 +126,10 @@ new socket.
> > For some applications, performance may be enhanced by using an
> > .Xr accept_filter 9
> > to pre-process incoming connections.
> > +.Pp
> > +Portable programs should not rely on the
> > +.Dv O_NONBLOCK
> > +property being inherited.
> > .Sh RETURN VALUES
> > The call returns \-1 on error.
> > If it succeeds, it returns a non-negative
> >
--
Robert Noland
FreeBSD
From imp at bsdimp.com Mon Nov 2 15:51:09 2009
From: imp at bsdimp.com (M. Warner Losh)
Date: Mon Nov 2 15:51:20 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To: <20091102102404.GP1293@hoeg.nl>
References: <20091101011212.GG1293@hoeg.nl>
<20091102100435.GA67211@walton.maths.tcd.ie>
<20091102102404.GP1293@hoeg.nl>
Message-ID: <20091102.084616.-1258100553.imp@bsdimp.com>
In message: <20091102102404.GP1293@hoeg.nl>
Ed Schouten writes:
: Hello David,
:
: * David Malone wrote:
: > Surely it is an API change, but not an ABI change? Code that used
: > to do:
: >
: > d.d_uid = 3;
: >
: > will no longer compile, but code that was comipled with the old
: > version will still run. I understand that the assignment doesn't
: > do anything useful, but I suppose there still could be code that
: > does it?
:
: Yes, in theory there could be pieces of code that do that, but keep in
: mind that d_uid was never meant to be used by device drivers. It was
: used by devfs internally, before cdevpriv existed.
:
: Looking at the SVN logs, it was introduced in March 2005, but it was
: already rendered useless in September that same year, when devfs was
: modified to just obtain the ownership/modes from the cdevpriv instead of
: the cdevsw.
:
: Interesting commits:
:
: - http://svn.freebsd.org/viewvc/base?view=revision&revision=143746
: - http://svn.freebsd.org/viewvc/base?view=revision&revision=150342
True, but you've now spent way more time than a version bump would
have taken on this. The first of these also does a version bump. :)
And you haven't answered my question: Have you confirmed that there's
no ABI changes on all platforms?
Warner
From rnoland at FreeBSD.org Mon Nov 2 15:53:33 2009
From: rnoland at FreeBSD.org (Robert Noland)
Date: Mon Nov 2 15:53:38 2009
Subject: svn commit: r198792 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/drm dev/xen/xenpci
Message-ID: <200911021553.nA2FrWpY061377@svn.freebsd.org>
Author: rnoland
Date: Mon Nov 2 15:53:32 2009
New Revision: 198792
URL: http://svn.freebsd.org/changeset/base/198792
Log:
MFC 198691
Fix blitter support for RS880 chips
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/drm/r600_blit.c
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/dev/drm/r600_blit.c
==============================================================================
--- stable/8/sys/dev/drm/r600_blit.c Mon Nov 2 15:43:54 2009 (r198791)
+++ stable/8/sys/dev/drm/r600_blit.c Mon Nov 2 15:53:32 2009 (r198792)
@@ -1367,7 +1367,7 @@ set_vtx_resource(drm_radeon_private_t *d
if (((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RV610) ||
((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RV620) ||
((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RS780) ||
- /*((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RS880) ||*/
+ ((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RS880) ||
((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RV710))
cp_set_surface_sync(dev_priv,
R600_TC_ACTION_ENA, 48, gpu_addr);
@@ -1509,7 +1509,7 @@ set_default_state(drm_radeon_private_t *
case CHIP_RV610:
case CHIP_RV620:
case CHIP_RS780:
- /*case CHIP_RS880:*/
+ case CHIP_RS880:
default:
num_ps_gprs = 84;
num_vs_gprs = 36;
@@ -1591,7 +1591,7 @@ set_default_state(drm_radeon_private_t *
if (((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RV610) ||
((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RV620) ||
((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RS780) ||
- /*((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RS880) ||*/
+ ((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RS880) ||
((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RV710))
sq_config = 0;
else
From ed at 80386.nl Mon Nov 2 15:54:15 2009
From: ed at 80386.nl (Ed Schouten)
Date: Mon Nov 2 15:54:26 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To: <20091102.084616.-1258100553.imp@bsdimp.com>
References: <20091101011212.GG1293@hoeg.nl>
<20091102100435.GA67211@walton.maths.tcd.ie>
<20091102102404.GP1293@hoeg.nl>
<20091102.084616.-1258100553.imp@bsdimp.com>
Message-ID: <20091102155414.GR1293@hoeg.nl>
* M. Warner Losh wrote:
> And you haven't answered my question: Have you confirmed that there's
> no ABI changes on all platforms?
Confirmed on all platforms? No. I've only tested it on i386 and amd64. I
think someone also tested it on arm, so this makes me believe other
architectures will also work as expected.
--
Ed Schouten
WWW: http://80386.nl/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091102/a12e2e77/attachment.pgp
From rnoland at FreeBSD.org Mon Nov 2 15:54:41 2009
From: rnoland at FreeBSD.org (Robert Noland)
Date: Mon Nov 2 15:55:08 2009
Subject: svn commit: r198793 - in stable/7/sys: . contrib/pf dev/drm
Message-ID: <200911021554.nA2FsfbD061435@svn.freebsd.org>
Author: rnoland
Date: Mon Nov 2 15:54:41 2009
New Revision: 198793
URL: http://svn.freebsd.org/changeset/base/198793
Log:
MFC 198691
Fix blitter support for RS880 chips
Modified:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/dev/drm/r600_blit.c
Modified: stable/7/sys/dev/drm/r600_blit.c
==============================================================================
--- stable/7/sys/dev/drm/r600_blit.c Mon Nov 2 15:53:32 2009 (r198792)
+++ stable/7/sys/dev/drm/r600_blit.c Mon Nov 2 15:54:41 2009 (r198793)
@@ -1367,7 +1367,7 @@ set_vtx_resource(drm_radeon_private_t *d
if (((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RV610) ||
((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RV620) ||
((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RS780) ||
- /*((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RS880) ||*/
+ ((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RS880) ||
((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RV710))
cp_set_surface_sync(dev_priv,
R600_TC_ACTION_ENA, 48, gpu_addr);
@@ -1509,7 +1509,7 @@ set_default_state(drm_radeon_private_t *
case CHIP_RV610:
case CHIP_RV620:
case CHIP_RS780:
- /*case CHIP_RS880:*/
+ case CHIP_RS880:
default:
num_ps_gprs = 84;
num_vs_gprs = 36;
@@ -1591,7 +1591,7 @@ set_default_state(drm_radeon_private_t *
if (((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RV610) ||
((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RV620) ||
((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RS780) ||
- /*((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RS880) ||*/
+ ((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RS880) ||
((dev_priv->flags & RADEON_FAMILY_MASK) == CHIP_RV710))
sq_config = 0;
else
From rnoland at FreeBSD.org Mon Nov 2 15:57:04 2009
From: rnoland at FreeBSD.org (Robert Noland)
Date: Mon Nov 2 15:58:25 2009
Subject: svn commit: r198794 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/drm dev/xen/xenpci
Message-ID: <200911021557.nA2Fv3g0061546@svn.freebsd.org>
Author: rnoland
Date: Mon Nov 2 15:57:03 2009
New Revision: 198794
URL: http://svn.freebsd.org/changeset/base/198794
Log:
MFC 198692
Use system specified memory barriers rather than rolling our own.
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/drm/drmP.h
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/dev/drm/drmP.h
==============================================================================
--- stable/8/sys/dev/drm/drmP.h Mon Nov 2 15:54:41 2009 (r198793)
+++ stable/8/sys/dev/drm/drmP.h Mon Nov 2 15:57:03 2009 (r198794)
@@ -223,23 +223,9 @@ typedef u_int8_t u8;
* DRM_WRITEMEMORYBARRIER() prevents reordering of writes.
* DRM_MEMORYBARRIER() prevents reordering of reads and writes.
*/
-#if defined(__i386__)
-#define DRM_READMEMORYBARRIER() __asm __volatile( \
- "lock; addl $0,0(%%esp)" : : : "memory");
-#define DRM_WRITEMEMORYBARRIER() __asm __volatile("" : : : "memory");
-#define DRM_MEMORYBARRIER() __asm __volatile( \
- "lock; addl $0,0(%%esp)" : : : "memory");
-#elif defined(__alpha__)
-#define DRM_READMEMORYBARRIER() alpha_mb();
-#define DRM_WRITEMEMORYBARRIER() alpha_wmb();
-#define DRM_MEMORYBARRIER() alpha_mb();
-#elif defined(__amd64__)
-#define DRM_READMEMORYBARRIER() __asm __volatile( \
- "lock; addl $0,0(%%rsp)" : : : "memory");
-#define DRM_WRITEMEMORYBARRIER() __asm __volatile("" : : : "memory");
-#define DRM_MEMORYBARRIER() __asm __volatile( \
- "lock; addl $0,0(%%rsp)" : : : "memory");
-#endif
+#define DRM_READMEMORYBARRIER() rmb()
+#define DRM_WRITEMEMORYBARRIER() wmb()
+#define DRM_MEMORYBARRIER() mb()
#define DRM_READ8(map, offset) \
*(volatile u_int8_t *)(((vm_offset_t)(map)->handle) + \
From rnoland at FreeBSD.org Mon Nov 2 15:59:56 2009
From: rnoland at FreeBSD.org (Robert Noland)
Date: Mon Nov 2 16:02:23 2009
Subject: svn commit: r198795 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/drm dev/xen/xenpci
Message-ID: <200911021559.nA2Fxu3D061658@svn.freebsd.org>
Author: rnoland
Date: Mon Nov 2 15:59:55 2009
New Revision: 198795
URL: http://svn.freebsd.org/changeset/base/198795
Log:
MFC 198695
A bit of cleanup work on radeon_freelist_get()
* Fix the main loop to search all buffers before sleeping.
* Remove dead code
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/drm/radeon_cp.c
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/dev/drm/radeon_cp.c
==============================================================================
--- stable/8/sys/dev/drm/radeon_cp.c Mon Nov 2 15:57:03 2009 (r198794)
+++ stable/8/sys/dev/drm/radeon_cp.c Mon Nov 2 15:59:55 2009 (r198795)
@@ -1860,8 +1860,8 @@ struct drm_buf *radeon_freelist_get(stru
for (t = 0; t < dev_priv->usec_timeout; t++) {
u32 done_age = GET_SCRATCH(dev_priv, 1);
DRM_DEBUG("done_age = %d\n", done_age);
- for (i = start; i < dma->buf_count; i++) {
- buf = dma->buflist[i];
+ for (i = 0; i < dma->buf_count; i++) {
+ buf = dma->buflist[start];
buf_priv = buf->dev_private;
if (buf->file_priv == NULL || (buf->pending &&
buf_priv->age <=
@@ -1870,7 +1870,8 @@ struct drm_buf *radeon_freelist_get(stru
buf->pending = 0;
return buf;
}
- start = 0;
+ if (++start >= dma->buf_count)
+ start = 0;
}
if (t) {
@@ -1879,47 +1880,9 @@ struct drm_buf *radeon_freelist_get(stru
}
}
- DRM_DEBUG("returning NULL!\n");
return NULL;
}
-#if 0
-struct drm_buf *radeon_freelist_get(struct drm_device * dev)
-{
- struct drm_device_dma *dma = dev->dma;
- drm_radeon_private_t *dev_priv = dev->dev_private;
- drm_radeon_buf_priv_t *buf_priv;
- struct drm_buf *buf;
- int i, t;
- int start;
- u32 done_age;
-
- done_age = radeon_read_ring_rptr(dev_priv, RADEON_SCRATCHOFF(1));
- if (++dev_priv->last_buf >= dma->buf_count)
- dev_priv->last_buf = 0;
-
- start = dev_priv->last_buf;
- dev_priv->stats.freelist_loops++;
-
- for (t = 0; t < 2; t++) {
- for (i = start; i < dma->buf_count; i++) {
- buf = dma->buflist[i];
- buf_priv = buf->dev_private;
- if (buf->file_priv == 0 || (buf->pending &&
- buf_priv->age <=
- done_age)) {
- dev_priv->stats.requested_bufs++;
- buf->pending = 0;
- return buf;
- }
- }
- start = 0;
- }
-
- return NULL;
-}
-#endif
-
void radeon_freelist_reset(struct drm_device * dev)
{
struct drm_device_dma *dma = dev->dma;
From rnoland at FreeBSD.org Mon Nov 2 16:00:20 2009
From: rnoland at FreeBSD.org (Robert Noland)
Date: Mon Nov 2 16:02:33 2009
Subject: svn commit: r198796 - in stable/7/sys: . contrib/pf dev/drm
Message-ID: <200911021600.nA2G01HF061711@svn.freebsd.org>
Author: rnoland
Date: Mon Nov 2 16:00:01 2009
New Revision: 198796
URL: http://svn.freebsd.org/changeset/base/198796
Log:
MFC 198695
A bit of cleanup work on radeon_freelist_get()
* Fix the main loop to search all buffers before sleeping.
* Remove dead code
Modified:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/dev/drm/radeon_cp.c
Modified: stable/7/sys/dev/drm/radeon_cp.c
==============================================================================
--- stable/7/sys/dev/drm/radeon_cp.c Mon Nov 2 15:59:55 2009 (r198795)
+++ stable/7/sys/dev/drm/radeon_cp.c Mon Nov 2 16:00:01 2009 (r198796)
@@ -1860,8 +1860,8 @@ struct drm_buf *radeon_freelist_get(stru
for (t = 0; t < dev_priv->usec_timeout; t++) {
u32 done_age = GET_SCRATCH(dev_priv, 1);
DRM_DEBUG("done_age = %d\n", done_age);
- for (i = start; i < dma->buf_count; i++) {
- buf = dma->buflist[i];
+ for (i = 0; i < dma->buf_count; i++) {
+ buf = dma->buflist[start];
buf_priv = buf->dev_private;
if (buf->file_priv == NULL || (buf->pending &&
buf_priv->age <=
@@ -1870,7 +1870,8 @@ struct drm_buf *radeon_freelist_get(stru
buf->pending = 0;
return buf;
}
- start = 0;
+ if (++start >= dma->buf_count)
+ start = 0;
}
if (t) {
@@ -1879,47 +1880,9 @@ struct drm_buf *radeon_freelist_get(stru
}
}
- DRM_DEBUG("returning NULL!\n");
return NULL;
}
-#if 0
-struct drm_buf *radeon_freelist_get(struct drm_device * dev)
-{
- struct drm_device_dma *dma = dev->dma;
- drm_radeon_private_t *dev_priv = dev->dev_private;
- drm_radeon_buf_priv_t *buf_priv;
- struct drm_buf *buf;
- int i, t;
- int start;
- u32 done_age;
-
- done_age = radeon_read_ring_rptr(dev_priv, RADEON_SCRATCHOFF(1));
- if (++dev_priv->last_buf >= dma->buf_count)
- dev_priv->last_buf = 0;
-
- start = dev_priv->last_buf;
- dev_priv->stats.freelist_loops++;
-
- for (t = 0; t < 2; t++) {
- for (i = start; i < dma->buf_count; i++) {
- buf = dma->buflist[i];
- buf_priv = buf->dev_private;
- if (buf->file_priv == 0 || (buf->pending &&
- buf_priv->age <=
- done_age)) {
- dev_priv->stats.requested_bufs++;
- buf->pending = 0;
- return buf;
- }
- }
- start = 0;
- }
-
- return NULL;
-}
-#endif
-
void radeon_freelist_reset(struct drm_device * dev)
{
struct drm_device_dma *dma = dev->dma;
From rnoland at FreeBSD.org Mon Nov 2 16:02:16 2009
From: rnoland at FreeBSD.org (Robert Noland)
Date: Mon Nov 2 16:03:12 2009
Subject: svn commit: r198797 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/drm dev/xen/xenpci
Message-ID: <200911021602.nA2G2Gsv061834@svn.freebsd.org>
Author: rnoland
Date: Mon Nov 2 16:02:16 2009
New Revision: 198797
URL: http://svn.freebsd.org/changeset/base/198797
Log:
MFC 198696
Cleanup in r600_blit
- Don't bother to assign vb until we know we have enough space
- Add variables for sx2, sy2, dx2, dy2 so that these aren't
calculated over and over, also reduce chance of errors.
- Use switch to assign color/format
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/drm/r600_blit.c
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/dev/drm/r600_blit.c
==============================================================================
--- stable/8/sys/dev/drm/r600_blit.c Mon Nov 2 16:00:01 2009 (r198796)
+++ stable/8/sys/dev/drm/r600_blit.c Mon Nov 2 16:02:16 2009 (r198797)
@@ -1719,7 +1719,10 @@ r600_blit_copy(struct drm_device *dev,
u32 *vb;
vb = (u32 *) ((char *)dev->agp_buffer_map->handle +
- dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
+ dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
+ DRM_DEBUG("src=0x%016llx, dst=0x%016llx, size=%d\n",
+ (unsigned long long)src_gpu_addr,
+ (unsigned long long)dst_gpu_addr, size_bytes);
if ((size_bytes & 3) || (src_gpu_addr & 3) || (dst_gpu_addr & 3)) {
max_bytes = 8192;
@@ -1757,7 +1760,7 @@ r600_blit_copy(struct drm_device *dev,
return;
set_shaders(dev);
vb = (u32 *) ((char *)dev->agp_buffer_map->handle +
- dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
+ dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
}
vb[0] = i2f(dst_x);
@@ -1847,7 +1850,7 @@ r600_blit_copy(struct drm_device *dev,
return;
set_shaders(dev);
vb = (u32 *) ((char *)dev->agp_buffer_map->handle +
- dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
+ dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
}
vb[0] = i2f(dst_x / 4);
@@ -1913,12 +1916,10 @@ r600_blit_swap(struct drm_device *dev,
{
drm_radeon_private_t *dev_priv = dev->dev_private;
int cb_format, tex_format;
+ int sx2, sy2, dx2, dy2;
u64 vb_addr;
u32 *vb;
- vb = (u32 *) ((char *)dev->agp_buffer_map->handle +
- dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
-
if ((dev_priv->blit_vb->used + 48) > dev_priv->blit_vb->total) {
dev_priv->blit_vb->used = 0;
radeon_cp_discard_buffer(dev, dev_priv->blit_vb);
@@ -1926,20 +1927,14 @@ r600_blit_swap(struct drm_device *dev,
if (!dev_priv->blit_vb)
return;
set_shaders(dev);
- vb = (u32 *) ((char *)dev->agp_buffer_map->handle +
- dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
}
+ vb = (u32 *) ((char *)dev->agp_buffer_map->handle +
+ dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
- if (cpp == 4) {
- cb_format = COLOR_8_8_8_8;
- tex_format = FMT_8_8_8_8;
- } else if (cpp == 2) {
- cb_format = COLOR_5_6_5;
- tex_format = FMT_5_6_5;
- } else {
- cb_format = COLOR_8;
- tex_format = FMT_8;
- }
+ sx2 = sx + w;
+ sy2 = sy + h;
+ dx2 = dx + w;
+ dy2 = dy + h;
vb[0] = i2f(dx);
vb[1] = i2f(dy);
@@ -1947,31 +1942,46 @@ r600_blit_swap(struct drm_device *dev,
vb[3] = i2f(sy);
vb[4] = i2f(dx);
- vb[5] = i2f(dy + h);
+ vb[5] = i2f(dy2);
vb[6] = i2f(sx);
- vb[7] = i2f(sy + h);
+ vb[7] = i2f(sy2);
+
+ vb[8] = i2f(dx2);
+ vb[9] = i2f(dy2);
+ vb[10] = i2f(sx2);
+ vb[11] = i2f(sy2);
- vb[8] = i2f(dx + w);
- vb[9] = i2f(dy + h);
- vb[10] = i2f(sx + w);
- vb[11] = i2f(sy + h);
+ switch(cpp) {
+ case 4:
+ cb_format = COLOR_8_8_8_8;
+ tex_format = FMT_8_8_8_8;
+ break;
+ case 2:
+ cb_format = COLOR_5_6_5;
+ tex_format = FMT_5_6_5;
+ break;
+ default:
+ cb_format = COLOR_8;
+ tex_format = FMT_8;
+ break;
+ }
/* src */
set_tex_resource(dev_priv, tex_format,
src_pitch / cpp,
- sy + h, src_pitch / cpp,
+ sy2, src_pitch / cpp,
src_gpu_addr);
cp_set_surface_sync(dev_priv,
- R600_TC_ACTION_ENA, (src_pitch * (sy + h)), src_gpu_addr);
+ R600_TC_ACTION_ENA, src_pitch * sy2, src_gpu_addr);
/* dst */
set_render_target(dev_priv, cb_format,
- dst_pitch / cpp, dy + h,
+ dst_pitch / cpp, dy2,
dst_gpu_addr);
/* scissors */
- set_scissors(dev_priv, dx, dy, dx + w, dy + h);
+ set_scissors(dev_priv, dx, dy, dx2, dy2);
/* Vertex buffer setup */
vb_addr = dev_priv->gart_buffers_offset +
@@ -1984,7 +1994,7 @@ r600_blit_swap(struct drm_device *dev,
cp_set_surface_sync(dev_priv,
R600_CB_ACTION_ENA | R600_CB0_DEST_BASE_ENA,
- dst_pitch * (dy + h), dst_gpu_addr);
+ dst_pitch * dy2, dst_gpu_addr);
dev_priv->blit_vb->used += 12 * 4;
}
From rnoland at FreeBSD.org Mon Nov 2 16:02:37 2009
From: rnoland at FreeBSD.org (Robert Noland)
Date: Mon Nov 2 16:03:32 2009
Subject: svn commit: r198798 - in stable/7/sys: . contrib/pf dev/drm
Message-ID: <200911021602.nA2G2a82061875@svn.freebsd.org>
Author: rnoland
Date: Mon Nov 2 16:02:36 2009
New Revision: 198798
URL: http://svn.freebsd.org/changeset/base/198798
Log:
MFC 198696
Cleanup in r600_blit
- Don't bother to assign vb until we know we have enough space
- Add variables for sx2, sy2, dx2, dy2 so that these aren't
calculated over and over, also reduce chance of errors.
- Use switch to assign color/format
Modified:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/dev/drm/r600_blit.c
Modified: stable/7/sys/dev/drm/r600_blit.c
==============================================================================
--- stable/7/sys/dev/drm/r600_blit.c Mon Nov 2 16:02:16 2009 (r198797)
+++ stable/7/sys/dev/drm/r600_blit.c Mon Nov 2 16:02:36 2009 (r198798)
@@ -1719,7 +1719,10 @@ r600_blit_copy(struct drm_device *dev,
u32 *vb;
vb = (u32 *) ((char *)dev->agp_buffer_map->handle +
- dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
+ dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
+ DRM_DEBUG("src=0x%016llx, dst=0x%016llx, size=%d\n",
+ (unsigned long long)src_gpu_addr,
+ (unsigned long long)dst_gpu_addr, size_bytes);
if ((size_bytes & 3) || (src_gpu_addr & 3) || (dst_gpu_addr & 3)) {
max_bytes = 8192;
@@ -1757,7 +1760,7 @@ r600_blit_copy(struct drm_device *dev,
return;
set_shaders(dev);
vb = (u32 *) ((char *)dev->agp_buffer_map->handle +
- dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
+ dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
}
vb[0] = i2f(dst_x);
@@ -1847,7 +1850,7 @@ r600_blit_copy(struct drm_device *dev,
return;
set_shaders(dev);
vb = (u32 *) ((char *)dev->agp_buffer_map->handle +
- dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
+ dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
}
vb[0] = i2f(dst_x / 4);
@@ -1913,12 +1916,10 @@ r600_blit_swap(struct drm_device *dev,
{
drm_radeon_private_t *dev_priv = dev->dev_private;
int cb_format, tex_format;
+ int sx2, sy2, dx2, dy2;
u64 vb_addr;
u32 *vb;
- vb = (u32 *) ((char *)dev->agp_buffer_map->handle +
- dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
-
if ((dev_priv->blit_vb->used + 48) > dev_priv->blit_vb->total) {
dev_priv->blit_vb->used = 0;
radeon_cp_discard_buffer(dev, dev_priv->blit_vb);
@@ -1926,20 +1927,14 @@ r600_blit_swap(struct drm_device *dev,
if (!dev_priv->blit_vb)
return;
set_shaders(dev);
- vb = (u32 *) ((char *)dev->agp_buffer_map->handle +
- dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
}
+ vb = (u32 *) ((char *)dev->agp_buffer_map->handle +
+ dev_priv->blit_vb->offset + dev_priv->blit_vb->used);
- if (cpp == 4) {
- cb_format = COLOR_8_8_8_8;
- tex_format = FMT_8_8_8_8;
- } else if (cpp == 2) {
- cb_format = COLOR_5_6_5;
- tex_format = FMT_5_6_5;
- } else {
- cb_format = COLOR_8;
- tex_format = FMT_8;
- }
+ sx2 = sx + w;
+ sy2 = sy + h;
+ dx2 = dx + w;
+ dy2 = dy + h;
vb[0] = i2f(dx);
vb[1] = i2f(dy);
@@ -1947,31 +1942,46 @@ r600_blit_swap(struct drm_device *dev,
vb[3] = i2f(sy);
vb[4] = i2f(dx);
- vb[5] = i2f(dy + h);
+ vb[5] = i2f(dy2);
vb[6] = i2f(sx);
- vb[7] = i2f(sy + h);
+ vb[7] = i2f(sy2);
+
+ vb[8] = i2f(dx2);
+ vb[9] = i2f(dy2);
+ vb[10] = i2f(sx2);
+ vb[11] = i2f(sy2);
- vb[8] = i2f(dx + w);
- vb[9] = i2f(dy + h);
- vb[10] = i2f(sx + w);
- vb[11] = i2f(sy + h);
+ switch(cpp) {
+ case 4:
+ cb_format = COLOR_8_8_8_8;
+ tex_format = FMT_8_8_8_8;
+ break;
+ case 2:
+ cb_format = COLOR_5_6_5;
+ tex_format = FMT_5_6_5;
+ break;
+ default:
+ cb_format = COLOR_8;
+ tex_format = FMT_8;
+ break;
+ }
/* src */
set_tex_resource(dev_priv, tex_format,
src_pitch / cpp,
- sy + h, src_pitch / cpp,
+ sy2, src_pitch / cpp,
src_gpu_addr);
cp_set_surface_sync(dev_priv,
- R600_TC_ACTION_ENA, (src_pitch * (sy + h)), src_gpu_addr);
+ R600_TC_ACTION_ENA, src_pitch * sy2, src_gpu_addr);
/* dst */
set_render_target(dev_priv, cb_format,
- dst_pitch / cpp, dy + h,
+ dst_pitch / cpp, dy2,
dst_gpu_addr);
/* scissors */
- set_scissors(dev_priv, dx, dy, dx + w, dy + h);
+ set_scissors(dev_priv, dx, dy, dx2, dy2);
/* Vertex buffer setup */
vb_addr = dev_priv->gart_buffers_offset +
@@ -1984,7 +1994,7 @@ r600_blit_swap(struct drm_device *dev,
cp_set_surface_sync(dev_priv,
R600_CB_ACTION_ENA | R600_CB0_DEST_BASE_ENA,
- dst_pitch * (dy + h), dst_gpu_addr);
+ dst_pitch * dy2, dst_gpu_addr);
dev_priv->blit_vb->used += 12 * 4;
}
From emaste at FreeBSD.org Mon Nov 2 16:22:59 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 16:23:05 2009
Subject: svn commit: r198799 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/aac dev/xen/xenpci
Message-ID: <200911021622.nA2GMxIS062407@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 16:22:59 2009
New Revision: 198799
URL: http://svn.freebsd.org/changeset/base/198799
Log:
MFC r198541:
Do first controller time sync after 1 minute, as in Adaptec's vendor
driver.
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/aac/aac.c
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/dev/aac/aac.c
==============================================================================
--- stable/8/sys/dev/aac/aac.c Mon Nov 2 16:02:36 2009 (r198798)
+++ stable/8/sys/dev/aac/aac.c Mon Nov 2 16:22:59 2009 (r198799)
@@ -354,7 +354,7 @@ aac_attach(struct aac_softc *sc)
}
mtx_lock(&sc->aac_io_lock);
- callout_reset(&sc->aac_daemontime, 30 * 60 * hz, aac_daemon, sc);
+ callout_reset(&sc->aac_daemontime, 60 * hz, aac_daemon, sc);
mtx_unlock(&sc->aac_io_lock);
return(0);
From emaste at FreeBSD.org Mon Nov 2 16:25:01 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 16:25:13 2009
Subject: svn commit: r198800 - in stable/7/sys: . contrib/pf dev/aac
Message-ID: <200911021625.nA2GP1cL062486@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 16:25:00 2009
New Revision: 198800
URL: http://svn.freebsd.org/changeset/base/198800
Log:
MFC r198541:
Do first controller time sync after 1 minute, as in Adaptec's vendor
driver.
Modified:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/dev/aac/aac.c
Modified: stable/7/sys/dev/aac/aac.c
==============================================================================
--- stable/7/sys/dev/aac/aac.c Mon Nov 2 16:22:59 2009 (r198799)
+++ stable/7/sys/dev/aac/aac.c Mon Nov 2 16:25:00 2009 (r198800)
@@ -354,7 +354,7 @@ aac_attach(struct aac_softc *sc)
}
mtx_lock(&sc->aac_io_lock);
- callout_reset(&sc->aac_daemontime, 30 * 60 * hz, aac_daemon, sc);
+ callout_reset(&sc->aac_daemontime, 60 * hz, aac_daemon, sc);
mtx_unlock(&sc->aac_io_lock);
return(0);
From emaste at FreeBSD.org Mon Nov 2 16:25:15 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 16:25:28 2009
Subject: svn commit: r198801 - in stable/6/sys: . conf contrib/pf dev/aac
dev/cxgb
Message-ID: <200911021625.nA2GPF3U062533@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 16:25:15 2009
New Revision: 198801
URL: http://svn.freebsd.org/changeset/base/198801
Log:
MFC r198541:
Do first controller time sync after 1 minute, as in Adaptec's vendor
driver.
Modified:
stable/6/sys/ (props changed)
stable/6/sys/conf/ (props changed)
stable/6/sys/contrib/pf/ (props changed)
stable/6/sys/dev/aac/aac.c
stable/6/sys/dev/cxgb/ (props changed)
Modified: stable/6/sys/dev/aac/aac.c
==============================================================================
--- stable/6/sys/dev/aac/aac.c Mon Nov 2 16:25:00 2009 (r198800)
+++ stable/6/sys/dev/aac/aac.c Mon Nov 2 16:25:15 2009 (r198801)
@@ -354,7 +354,7 @@ aac_attach(struct aac_softc *sc)
}
mtx_lock(&sc->aac_io_lock);
- callout_reset(&sc->aac_daemontime, 30 * 60 * hz, aac_daemon, sc);
+ callout_reset(&sc->aac_daemontime, 60 * hz, aac_daemon, sc);
mtx_unlock(&sc->aac_io_lock);
return(0);
From emaste at FreeBSD.org Mon Nov 2 16:27:34 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 16:27:40 2009
Subject: svn commit: r198802 - in stable/8/usr.sbin/ntp: . doc
Message-ID: <200911021627.nA2GRYPj062637@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 16:27:34 2009
New Revision: 198802
URL: http://svn.freebsd.org/changeset/base/198802
Log:
MFC r198029:
Correct typo: thetime -> the time
PR: docs/139447
Submitted by: Guido Falsi mad at madpilot dot net
Modified:
stable/8/usr.sbin/ntp/ (props changed)
stable/8/usr.sbin/ntp/doc/ntpd.8
Modified: stable/8/usr.sbin/ntp/doc/ntpd.8
==============================================================================
--- stable/8/usr.sbin/ntp/doc/ntpd.8 Mon Nov 2 16:25:15 2009 (r198801)
+++ stable/8/usr.sbin/ntp/doc/ntpd.8 Mon Nov 2 16:27:34 2009 (r198802)
@@ -121,7 +121,7 @@ Normally,
.Nm
exits with a message to the system log if the offset exceeds
the panic threshold, which is 1000 s by default.
-This option allows thetime to be set to any value without restriction;
+This option allows the time to be set to any value without restriction;
however, this can happen only once.
If the threshold is exceeded after that,
.Nm
From emaste at FreeBSD.org Mon Nov 2 16:29:04 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 16:29:11 2009
Subject: svn commit: r198803 - in stable/7/usr.sbin/ntp: . doc
Message-ID: <200911021629.nA2GT4jq062726@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 16:29:04 2009
New Revision: 198803
URL: http://svn.freebsd.org/changeset/base/198803
Log:
MFC r198029:
Correct typo: thetime -> the time
PR: docs/139447
Submitted by: Guido Falsi mad at madpilot dot net
Modified:
stable/7/usr.sbin/ntp/ (props changed)
stable/7/usr.sbin/ntp/doc/ntpd.8
Modified: stable/7/usr.sbin/ntp/doc/ntpd.8
==============================================================================
--- stable/7/usr.sbin/ntp/doc/ntpd.8 Mon Nov 2 16:27:34 2009 (r198802)
+++ stable/7/usr.sbin/ntp/doc/ntpd.8 Mon Nov 2 16:29:04 2009 (r198803)
@@ -121,7 +121,7 @@ Normally,
.Nm
exits with a message to the system log if the offset exceeds
the panic threshold, which is 1000 s by default.
-This option allows thetime to be set to any value without restriction;
+This option allows the time to be set to any value without restriction;
however, this can happen only once.
If the threshold is exceeded after that,
.Nm
From emaste at FreeBSD.org Mon Nov 2 16:29:54 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 16:30:11 2009
Subject: svn commit: r198804 - in stable/6/usr.sbin/ntp: . doc
Message-ID: <200911021629.nA2GTsmw062780@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 16:29:54 2009
New Revision: 198804
URL: http://svn.freebsd.org/changeset/base/198804
Log:
MFC r198029:
Correct typo: thetime -> the time
PR: docs/139447
Submitted by: Guido Falsi mad at madpilot dot net
Modified:
stable/6/usr.sbin/ntp/ (props changed)
stable/6/usr.sbin/ntp/doc/ (props changed)
stable/6/usr.sbin/ntp/doc/ntpd.8
Modified: stable/6/usr.sbin/ntp/doc/ntpd.8
==============================================================================
--- stable/6/usr.sbin/ntp/doc/ntpd.8 Mon Nov 2 16:29:04 2009 (r198803)
+++ stable/6/usr.sbin/ntp/doc/ntpd.8 Mon Nov 2 16:29:54 2009 (r198804)
@@ -120,7 +120,7 @@ Normally,
.Nm
exits with a message to the system log if the offset exceeds
the panic threshold, which is 1000 s by default.
-This option allows thetime to be set to any value without restriction;
+This option allows the time to be set to any value without restriction;
however, this can happen only once.
If the threshold is exceeded after that,
.Nm
From emaste at FreeBSD.org Mon Nov 2 16:32:33 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 16:32:39 2009
Subject: svn commit: r198805 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/xen/xenpci kern
Message-ID: <200911021632.nA2GWXLC062886@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 16:32:32 2009
New Revision: 198805
URL: http://svn.freebsd.org/changeset/base/198805
Log:
MFC r197692:
In fill_kinfo_thread, copy the thread's name into struct kinfo_proc even
if it is empty. Otherwise the previous thread's name would remain in the
struct and then be reported for this thread.
Submitted by: Ryan Stone
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
stable/8/sys/kern/kern_proc.c
Modified: stable/8/sys/kern/kern_proc.c
==============================================================================
--- stable/8/sys/kern/kern_proc.c Mon Nov 2 16:29:54 2009 (r198804)
+++ stable/8/sys/kern/kern_proc.c Mon Nov 2 16:32:32 2009 (r198805)
@@ -847,8 +847,7 @@ fill_kinfo_thread(struct thread *td, str
strlcpy(kp->ki_wmesg, td->td_wmesg, sizeof(kp->ki_wmesg));
else
bzero(kp->ki_wmesg, sizeof(kp->ki_wmesg));
- if (td->td_name[0] != '\0')
- strlcpy(kp->ki_ocomm, td->td_name, sizeof(kp->ki_ocomm));
+ strlcpy(kp->ki_ocomm, td->td_name, sizeof(kp->ki_ocomm));
if (TD_ON_LOCK(td)) {
kp->ki_kiflag |= KI_LOCKBLOCK;
strlcpy(kp->ki_lockname, td->td_lockname,
From emaste at FreeBSD.org Mon Nov 2 16:46:07 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 16:46:14 2009
Subject: svn commit: r198806 - in stable/8/sys: . amd64/include/xen
boot/i386/libi386 cddl/contrib/opensolaris contrib/dev/acpica
contrib/pf dev/xen/xenpci
Message-ID: <200911021646.nA2Gk7Sq063223@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 16:46:06 2009
New Revision: 198806
URL: http://svn.freebsd.org/changeset/base/198806
Log:
MFC r197082:
If the pxe client is told to use / as the root path, honour that rather
of trying to mount /pxeroot instead.
PR: i386/106493
Submitted by: Andrey Russev
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/boot/i386/libi386/pxe.c
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/boot/i386/libi386/pxe.c
==============================================================================
--- stable/8/sys/boot/i386/libi386/pxe.c Mon Nov 2 16:32:32 2009 (r198805)
+++ stable/8/sys/boot/i386/libi386/pxe.c Mon Nov 2 16:46:06 2009 (r198806)
@@ -282,7 +282,7 @@ pxe_open(struct open_file *f, ...)
bootp(pxe_sock, BOOTP_PXE);
if (rootip.s_addr == 0)
rootip.s_addr = bootplayer.sip;
- if (!rootpath[1])
+ if (!rootpath[0])
strcpy(rootpath, PXENFSROOTPATH);
for (i = 0; rootpath[i] != '\0' && i < FNAME_SIZE; i++)
From emaste at FreeBSD.org Mon Nov 2 16:46:54 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 16:47:00 2009
Subject: svn commit: r198807 - in stable/7/sys: . boot/i386/libi386
contrib/pf
Message-ID: <200911021646.nA2GkrCk063272@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 16:46:53 2009
New Revision: 198807
URL: http://svn.freebsd.org/changeset/base/198807
Log:
MFC r197082:
If the pxe client is told to use / as the root path, honour that rather
of trying to mount /pxeroot instead.
PR: i386/106493
Submitted by: Andrey Russev
Modified:
stable/7/sys/ (props changed)
stable/7/sys/boot/i386/libi386/pxe.c
stable/7/sys/contrib/pf/ (props changed)
Modified: stable/7/sys/boot/i386/libi386/pxe.c
==============================================================================
--- stable/7/sys/boot/i386/libi386/pxe.c Mon Nov 2 16:46:06 2009 (r198806)
+++ stable/7/sys/boot/i386/libi386/pxe.c Mon Nov 2 16:46:53 2009 (r198807)
@@ -282,7 +282,7 @@ pxe_open(struct open_file *f, ...)
bootp(pxe_sock, BOOTP_PXE);
if (rootip.s_addr == 0)
rootip.s_addr = bootplayer.sip;
- if (!rootpath[1])
+ if (!rootpath[0])
strcpy(rootpath, PXENFSROOTPATH);
for (i = 0; rootpath[i] != '\0' && i < FNAME_SIZE; i++)
From emaste at FreeBSD.org Mon Nov 2 16:49:57 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 16:50:13 2009
Subject: svn commit: r198808 - in stable/6/sys: . boot/i386/libi386 conf
contrib/pf dev/cxgb
Message-ID: <200911021649.nA2GnvkY063380@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 16:49:57 2009
New Revision: 198808
URL: http://svn.freebsd.org/changeset/base/198808
Log:
MFC r197082:
If the pxe client is told to use / as the root path, honour that rather
of trying to mount /pxeroot instead.
PR: i386/106493
Submitted by: Andrey Russev
Modified:
stable/6/sys/ (props changed)
stable/6/sys/boot/i386/libi386/pxe.c
stable/6/sys/conf/ (props changed)
stable/6/sys/contrib/pf/ (props changed)
stable/6/sys/dev/cxgb/ (props changed)
Modified: stable/6/sys/boot/i386/libi386/pxe.c
==============================================================================
--- stable/6/sys/boot/i386/libi386/pxe.c Mon Nov 2 16:46:53 2009 (r198807)
+++ stable/6/sys/boot/i386/libi386/pxe.c Mon Nov 2 16:49:57 2009 (r198808)
@@ -282,7 +282,7 @@ pxe_open(struct open_file *f, ...)
bootp(pxe_sock, BOOTP_PXE);
if (rootip.s_addr == 0)
rootip.s_addr = bootplayer.sip;
- if (!rootpath[1])
+ if (!rootpath[0])
strcpy(rootpath, PXENFSROOTPATH);
for (i = 0; rootpath[i] != '\0' && i < FNAME_SIZE; i++)
From emaste at FreeBSD.org Mon Nov 2 16:54:24 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 16:54:41 2009
Subject: svn commit: r198809 - in stable/8/sys: . amd64/include/xen
cddl/contrib/opensolaris contrib/dev/acpica contrib/pf
dev/aac dev/xen/xenpci
Message-ID: <200911021654.nA2GsOo3063516@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 16:54:23 2009
New Revision: 198809
URL: http://svn.freebsd.org/changeset/base/198809
Log:
MFC r197011:
Increase AAC_CMD_TIMEOUT from 30s to 120s to help avoid spurious
"COMMAND 0x........ TIMEOUT AFTER .. SECONDS" messages. Any commands
that get truly stuck will still trigger the warning and the hardware
health check, just a little bit later.
Modified:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/aac/aacvar.h
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/dev/aac/aacvar.h
==============================================================================
--- stable/8/sys/dev/aac/aacvar.h Mon Nov 2 16:49:57 2009 (r198808)
+++ stable/8/sys/dev/aac/aacvar.h Mon Nov 2 16:54:23 2009 (r198809)
@@ -88,7 +88,7 @@
/*
* Timeout for normal commands
*/
-#define AAC_CMD_TIMEOUT 30 /* seconds */
+#define AAC_CMD_TIMEOUT 120 /* seconds */
/*
* Rate at which we periodically check for timed out commands and kick the
From emaste at FreeBSD.org Mon Nov 2 16:55:34 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 16:56:34 2009
Subject: svn commit: r198810 - in stable/7/sys: . contrib/pf dev/aac
Message-ID: <200911021655.nA2GtYrg063605@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 16:55:33 2009
New Revision: 198810
URL: http://svn.freebsd.org/changeset/base/198810
Log:
MFC r197011:
Increase AAC_CMD_TIMEOUT from 30s to 120s to help avoid spurious
"COMMAND 0x........ TIMEOUT AFTER .. SECONDS" messages. Any commands
that get truly stuck will still trigger the warning and the hardware
health check, just a little bit later.
Modified:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
stable/7/sys/dev/aac/aacvar.h
Modified: stable/7/sys/dev/aac/aacvar.h
==============================================================================
--- stable/7/sys/dev/aac/aacvar.h Mon Nov 2 16:54:23 2009 (r198809)
+++ stable/7/sys/dev/aac/aacvar.h Mon Nov 2 16:55:33 2009 (r198810)
@@ -88,7 +88,7 @@
/*
* Timeout for normal commands
*/
-#define AAC_CMD_TIMEOUT 30 /* seconds */
+#define AAC_CMD_TIMEOUT 120 /* seconds */
/*
* Rate at which we periodically check for timed out commands and kick the
From ivoras at FreeBSD.org Mon Nov 2 16:56:59 2009
From: ivoras at FreeBSD.org (Ivan Voras)
Date: Mon Nov 2 16:57:44 2009
Subject: svn commit: r198811 - head/sys/vm
Message-ID: <200911021656.nA2GuxK1063687@svn.freebsd.org>
Author: ivoras
Date: Mon Nov 2 16:56:59 2009
New Revision: 198811
URL: http://svn.freebsd.org/changeset/base/198811
Log:
Add sysctl documentation strings. The descriptions are derived
from tuning(7). One of the descriptions references tuning(7) because
it is too complex to adequatly describe here (it is not a simple
boolean sysctl) and users should be warned to that.
Reviewed by: alc, kib
Approved by: gnn (mentor)
Modified:
head/sys/vm/swap_pager.c
Modified: head/sys/vm/swap_pager.c
==============================================================================
--- head/sys/vm/swap_pager.c Mon Nov 2 16:55:33 2009 (r198810)
+++ head/sys/vm/swap_pager.c Mon Nov 2 16:56:59 2009 (r198811)
@@ -155,11 +155,15 @@ int swap_pager_avail;
static int swdev_syscall_active = 0; /* serialize swap(on|off) */
static vm_ooffset_t swap_total;
-SYSCTL_QUAD(_vm, OID_AUTO, swap_total, CTLFLAG_RD, &swap_total, 0, "");
+SYSCTL_QUAD(_vm, OID_AUTO, swap_total, CTLFLAG_RD, &swap_total, 0,
+ "Total amount of available swap storage.");
static vm_ooffset_t swap_reserved;
-SYSCTL_QUAD(_vm, OID_AUTO, swap_reserved, CTLFLAG_RD, &swap_reserved, 0, "");
+SYSCTL_QUAD(_vm, OID_AUTO, swap_reserved, CTLFLAG_RD, &swap_reserved, 0,
+ "Amount of swap storage needed to back all allocated anonymous memory.");
static int overcommit = 0;
-SYSCTL_INT(_vm, OID_AUTO, overcommit, CTLFLAG_RW, &overcommit, 0, "");
+SYSCTL_INT(_vm, OID_AUTO, overcommit, CTLFLAG_RW, &overcommit, 0,
+ "Configure virtual memory overcommit behavior. See tuning(7) "
+ "for details.");
/* bits from overcommit */
#define SWAP_RESERVE_FORCE_ON (1 << 0)
From alc at FreeBSD.org Mon Nov 2 17:45:40 2009
From: alc at FreeBSD.org (Alan Cox)
Date: Mon Nov 2 17:46:12 2009
Subject: svn commit: r198812 - head/sys/vm
Message-ID: <200911021745.nA2Hjewx064713@svn.freebsd.org>
Author: alc
Date: Mon Nov 2 17:45:39 2009
New Revision: 198812
URL: http://svn.freebsd.org/changeset/base/198812
Log:
Avoid pointless calls to pmap_protect().
Reviewed by: kib
Modified:
head/sys/vm/vm_map.c
Modified: head/sys/vm/vm_map.c
==============================================================================
--- head/sys/vm/vm_map.c Mon Nov 2 16:56:59 2009 (r198811)
+++ head/sys/vm/vm_map.c Mon Nov 2 17:45:39 2009 (r198812)
@@ -1914,10 +1914,10 @@ vm_map_protect(vm_map_t map, vm_offset_t
}
/*
- * Update physical map if necessary. Worry about copy-on-write
- * here.
+ * When restricting access, update the physical map. Worry
+ * about copy-on-write here.
*/
- if (current->protection != old_prot) {
+ if ((old_prot & ~current->protection) != 0) {
#define MASK(entry) (((entry)->eflags & MAP_ENTRY_COW) ? ~VM_PROT_WRITE : \
VM_PROT_ALL)
pmap_protect(map->pmap, current->start,
From xcllnt at mac.com Mon Nov 2 18:08:21 2009
From: xcllnt at mac.com (Marcel Moolenaar)
Date: Mon Nov 2 18:08:32 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To: <20091102155414.GR1293@hoeg.nl>
References: <20091101011212.GG1293@hoeg.nl>
<20091102100435.GA67211@walton.maths.tcd.ie>
<20091102102404.GP1293@hoeg.nl>
<20091102.084616.-1258100553.imp@bsdimp.com>
<20091102155414.GR1293@hoeg.nl>
Message-ID:
On Nov 2, 2009, at 7:54 AM, Ed Schouten wrote:
> * M. Warner Losh wrote:
>> And you haven't answered my question: Have you confirmed that there's
>> no ABI changes on all platforms?
>
> Confirmed on all platforms? No. I've only tested it on i386 and
> amd64. I
> think someone also tested it on arm, so this makes me believe other
> architectures will also work as expected.
When you bank on alignment, don't just test i386 and amd64.
Please put in the extra effort to contact platform owners
to give you a thumbs up.
While I'm responding: please do a version bump as Warner
suggested. The pain of needing one without having done so,
is infinitely more than the effort or repo bloat can be
together.
Oh, and no, I don't think this changes the ABI :-)
For a change that does change the ABI: revision 198506
tcsh(1) dumps core with a sig 11...
Trick or treat...
--
Marcel Moolenaar
xcllnt@mac.com
From yongari at FreeBSD.org Mon Nov 2 18:15:11 2009
From: yongari at FreeBSD.org (Pyun YongHyeon)
Date: Mon Nov 2 18:15:18 2009
Subject: svn commit: r198813 - head/sys/dev/mii
Message-ID: <200911021815.nA2IFBPr065404@svn.freebsd.org>
Author: yongari
Date: Mon Nov 2 18:15:11 2009
New Revision: 198813
URL: http://svn.freebsd.org/changeset/base/198813
Log:
Add BCM5761 PHY id.
Modified:
head/sys/dev/mii/brgphy.c
head/sys/dev/mii/miidevs
Modified: head/sys/dev/mii/brgphy.c
==============================================================================
--- head/sys/dev/mii/brgphy.c Mon Nov 2 17:45:39 2009 (r198812)
+++ head/sys/dev/mii/brgphy.c Mon Nov 2 18:15:11 2009 (r198813)
@@ -134,6 +134,7 @@ static const struct mii_phydesc brgphys[
MII_PHY_DESC(xxBROADCOM_ALT1, BCM5709CAX),
MII_PHY_DESC(xxBROADCOM_ALT1, BCM5722),
MII_PHY_DESC(xxBROADCOM_ALT1, BCM5709C),
+ MII_PHY_DESC(xxBROADCOM_ALT1, BCM5761),
MII_PHY_DESC(BROADCOM2, BCM5906),
MII_PHY_END
};
Modified: head/sys/dev/mii/miidevs
==============================================================================
--- head/sys/dev/mii/miidevs Mon Nov 2 17:45:39 2009 (r198812)
+++ head/sys/dev/mii/miidevs Mon Nov 2 18:15:11 2009 (r198813)
@@ -154,6 +154,7 @@ model xxBROADCOM_ALT1 BCM5708S 0x0015 BC
model xxBROADCOM_ALT1 BCM5709CAX 0x002c BCM5709C(AX) 10/100/1000baseTX PHY
model xxBROADCOM_ALT1 BCM5722 0x002d BCM5722 10/100/1000baseTX PHY
model xxBROADCOM_ALT1 BCM5709C 0x003c BCM5709C 10/100/1000baseTX PHY
+model xxBROADCOM_ALT1 BCM5761 0x003d BCM5761 10/100/1000baseTX PHY
model BROADCOM2 BCM5906 0x0004 BCM5906 10/100baseTX PHY
/* Cicada Semiconductor PHYs (now owned by Vitesse?) */
From cperciva at freebsd.org Mon Nov 2 18:20:25 2009
From: cperciva at freebsd.org (Colin Percival)
Date: Mon Nov 2 18:20:37 2009
Subject: svn commit: r198781 - head/lib/libc/sys
In-Reply-To:
References: <200911020721.nA27LDq1048764@svn.freebsd.org>
Message-ID: <4AEF22E3.5070701@freebsd.org>
Robert Watson wrote:
> On Mon, 2 Nov 2009, Colin Percival wrote:
>> Attempt to reduce accidental foot-shooting by pointing out that
>> accept(2)ed sockets do not necessarily inherit O_NONBLOCK from
>> listening sockets on non-FreeBSD platforms.
>
> I wonder how much trouble we should go to to document bugs in other
> systems as non-portabilities for features that work in our system.
I don't think there's any simple rule to apply here except "use common
sense". One can argue that FreeBSD man pages exist for the purpose of
documenting FreeBSD; but I'd also like to think that FreeBSD is a good
development platform for writing portable applications, so alerting our
users to potentially non-portable code certainly has some value. (And
there are many other examples of "portable programs should not..." in
our man pages, not just the one I added.)
The non-portability I just documented was a particularly obnoxious one,
since in event-driven code it can go unnoticed for a long time -- as I
just recently discovered.
> I think a more general caution for accept(2) might instead be:
>
> BUGS
> The inheritence of socket options from a listen socket to a newly
> accepted socket is inconsistent across protocols, and non-portable.
I was originally going to write it that way, but when I looked at the
existing text I saw that it only mentioned inheriting O_NONBLOCK and said
nothing about other options -- so I figured that it was appropriate to
follow suit and only mention O_NONBLOCK in saying what was non-portable.
--
Colin Percival
Security Officer, FreeBSD | freebsd.org | The power to serve
Founder / author, Tarsnap | tarsnap.com | Online backups for the truly paranoid
From rwatson at FreeBSD.org Mon Nov 2 18:29:16 2009
From: rwatson at FreeBSD.org (Robert N. M. Watson)
Date: Mon Nov 2 18:29:29 2009
Subject: svn commit: r198781 - head/lib/libc/sys
In-Reply-To: <4AEF22E3.5070701@freebsd.org>
References: <200911020721.nA27LDq1048764@svn.freebsd.org>
<4AEF22E3.5070701@freebsd.org>
Message-ID:
On 2 Nov 2009, at 18:20, Colin Percival wrote:
>> I think a more general caution for accept(2) might instead be:
>>
>> BUGS
>> The inheritence of socket options from a listen socket to a newly
>> accepted socket is inconsistent across protocols, and non-
>> portable.
>
> I was originally going to write it that way, but when I looked at the
> existing text I saw that it only mentioned inheriting O_NONBLOCK and
> said
> nothing about other options -- so I figured that it was appropriate to
> follow suit and only mention O_NONBLOCK in saying what was non-
> portable.
We preserve a number of socket options and other properties across
accept(2), but not all. For example, we do preserve most socket-level
options, linger state, routing fib number, and socket buffer sizing/
watermarks, as well as many connection properties such as TCP_NODELAY.
However, if history is anything to go by, we also fail to preserve
quite a few properties, and we've had a number of bug fixes over the
years topping up the list of things inherited over accept.
Robert
From yongari at FreeBSD.org Mon Nov 2 18:35:07 2009
From: yongari at FreeBSD.org (Pyun YongHyeon)
Date: Mon Nov 2 18:35:14 2009
Subject: svn commit: r198814 - head/sys/dev/re
Message-ID: <200911021835.nA2IZ6WI065996@svn.freebsd.org>
Author: yongari
Date: Mon Nov 2 18:35:05 2009
New Revision: 198814
URL: http://svn.freebsd.org/changeset/base/198814
Log:
Add a check to know whether driver is still running after
reacquiring driver lock in Rx handler. re(4) drops a driver lock
before passing received frame to upper stack and reacquire the
lock. During the time window ioctl calls could be executed and if
the ioctl was interface down request, driver will stop the
controller and free allocated mbufs. After that when driver comes
back to Rx handler again it does not know what was happend so it
could access free mbufs which in turn cause panic.
Reported by: Norbert Papke < npapk <> acm dot org >
Tested by: Norbert Papke < npapk <> acm dot org >
Modified:
head/sys/dev/re/if_re.c
Modified: head/sys/dev/re/if_re.c
==============================================================================
--- head/sys/dev/re/if_re.c Mon Nov 2 18:15:11 2009 (r198813)
+++ head/sys/dev/re/if_re.c Mon Nov 2 18:35:05 2009 (r198814)
@@ -1817,6 +1817,8 @@ re_rxeof(struct rl_softc *sc, int *rx_np
for (i = sc->rl_ldata.rl_rx_prodidx; maxpkt > 0;
i = RL_RX_DESC_NXT(sc, i)) {
+ if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0)
+ break;
cur_rx = &sc->rl_ldata.rl_rx_list[i];
rxstat = le32toh(cur_rx->rl_cmdstat);
if ((rxstat & RL_RDESC_STAT_OWN) != 0)
From alc at FreeBSD.org Mon Nov 2 18:44:02 2009
From: alc at FreeBSD.org (Alan Cox)
Date: Mon Nov 2 18:45:46 2009
Subject: svn commit: r198815 - stable/8/lib/libc/stdlib
Message-ID: <200911021844.nA2Ii2br066253@svn.freebsd.org>
Author: alc
Date: Mon Nov 2 18:44:01 2009
New Revision: 198815
URL: http://svn.freebsd.org/changeset/base/198815
Log:
MFC r197524
Make malloc(3) superpage aware.
Modified:
stable/8/lib/libc/stdlib/ (props changed)
stable/8/lib/libc/stdlib/malloc.3
stable/8/lib/libc/stdlib/malloc.c
Modified: stable/8/lib/libc/stdlib/malloc.3
==============================================================================
--- stable/8/lib/libc/stdlib/malloc.3 Mon Nov 2 18:35:05 2009 (r198814)
+++ stable/8/lib/libc/stdlib/malloc.3 Mon Nov 2 18:44:01 2009 (r198815)
@@ -32,7 +32,7 @@
.\" @(#)malloc.3 8.1 (Berkeley) 6/4/93
.\" $FreeBSD$
.\"
-.Dd August 26, 2008
+.Dd September 26, 2009
.Dt MALLOC 3
.Os
.Sh NAME
@@ -245,7 +245,8 @@ will be initialized to 0x5a.
This is intended for debugging and will impact performance negatively.
.It K
Double/halve the virtual memory chunk size.
-The default chunk size is 1 MB.
+The default chunk size is the maximum of 1 MB and the largest
+page size that is less than or equal to 4 MB.
.It M
Use
.Xr mmap 2
@@ -561,6 +562,7 @@ _malloc_options = "X";
.Xr alloca 3 ,
.Xr atexit 3 ,
.Xr getpagesize 3 ,
+.Xr getpagesizes 3 ,
.Xr memory 3 ,
.Xr posix_memalign 3
.Sh STANDARDS
Modified: stable/8/lib/libc/stdlib/malloc.c
==============================================================================
--- stable/8/lib/libc/stdlib/malloc.c Mon Nov 2 18:35:05 2009 (r198814)
+++ stable/8/lib/libc/stdlib/malloc.c Mon Nov 2 18:44:01 2009 (r198815)
@@ -4795,6 +4795,21 @@ malloc_init_hard(void)
}
}
+ /*
+ * Increase the chunk size to the largest page size that is greater
+ * than the default chunk size and less than or equal to 4MB.
+ */
+ {
+ size_t pagesizes[MAXPAGESIZES];
+ int k, nsizes;
+
+ nsizes = getpagesizes(pagesizes, MAXPAGESIZES);
+ for (k = 0; k < nsizes; k++)
+ if (pagesizes[k] <= (1LU << 22))
+ while ((1LU << opt_chunk_2pow) < pagesizes[k])
+ opt_chunk_2pow++;
+ }
+
for (i = 0; i < 3; i++) {
unsigned j;
From rpaulo at FreeBSD.org Mon Nov 2 18:51:24 2009
From: rpaulo at FreeBSD.org (Rui Paulo)
Date: Mon Nov 2 18:51:36 2009
Subject: svn commit: r198816 - head/sys/compat/ndis
Message-ID: <200911021851.nA2IpOZ4066444@svn.freebsd.org>
Author: rpaulo
Date: Mon Nov 2 18:51:24 2009
New Revision: 198816
URL: http://svn.freebsd.org/changeset/base/198816
Log:
Fix a non-style change that snuck in.
Spotted by: danfe
Modified:
head/sys/compat/ndis/kern_ndis.c
Modified: head/sys/compat/ndis/kern_ndis.c
==============================================================================
--- head/sys/compat/ndis/kern_ndis.c Mon Nov 2 18:44:01 2009 (r198815)
+++ head/sys/compat/ndis/kern_ndis.c Mon Nov 2 18:51:24 2009 (r198816)
@@ -1200,7 +1200,7 @@ ndis_init_nic(arg)
NDIS_LOCK(sc);
sc->ndis_block->nmb_miniportadapterctx = NULL;
NDIS_UNLOCK(sc);
- return (status);
+ return (ENXIO);
}
/*
From max at love2party.net Mon Nov 2 18:55:05 2009
From: max at love2party.net (Max Laier)
Date: Mon Nov 2 18:55:16 2009
Subject: svn commit: r198781 - head/lib/libc/sys
In-Reply-To: <4AEF22E3.5070701@freebsd.org>
References: <200911020721.nA27LDq1048764@svn.freebsd.org>
<4AEF22E3.5070701@freebsd.org>
Message-ID: <200911021955.02459.max@love2party.net>
On Monday 02 November 2009 19:20:19 Colin Percival wrote:
> Robert Watson wrote:
> > On Mon, 2 Nov 2009, Colin Percival wrote:
> >> Attempt to reduce accidental foot-shooting by pointing out that
> >> accept(2)ed sockets do not necessarily inherit O_NONBLOCK from
> >> listening sockets on non-FreeBSD platforms.
> >
> > I wonder how much trouble we should go to to document bugs in other
> > systems as non-portabilities for features that work in our system.
>
> I don't think there's any simple rule to apply here except "use common
> sense". One can argue that FreeBSD man pages exist for the purpose of
> documenting FreeBSD; but I'd also like to think that FreeBSD is a good
> development platform for writing portable applications, so alerting our
> users to potentially non-portable code certainly has some value. (And
+1 ... FreeBSD is such a great development platform specifically because of
the complete man page collection. I'd argue, however, that we should keep the
portability notes to the fact that there might be a difference - without going
into too much detail what/where and why that difference is. In addition, the
more detail we add, the more likely it is that the information grows stale as
others realize that they should follow our lead ;)
> there are many other examples of "portable programs should not..." in
> our man pages, not just the one I added.)
>
> The non-portability I just documented was a particularly obnoxious one,
> since in event-driven code it can go unnoticed for a long time -- as I
> just recently discovered.
>
> > I think a more general caution for accept(2) might instead be:
> >
> > BUGS
> > The inheritence of socket options from a listen socket to a newly
> > accepted socket is inconsistent across protocols, and non-portable.
>
> I was originally going to write it that way, but when I looked at the
> existing text I saw that it only mentioned inheriting O_NONBLOCK and said
> nothing about other options -- so I figured that it was appropriate to
> follow suit and only mention O_NONBLOCK in saying what was non-portable.
>
--
/"\ Best regards, | mlaier@freebsd.org
\ / Max Laier | ICQ #67774661
X http://pf4freebsd.love2party.net/ | mlaier@EFnet
/ \ ASCII Ribbon Campaign | Against HTML Mail and News
From emaste at FreeBSD.org Mon Nov 2 19:01:20 2009
From: emaste at FreeBSD.org (Ed Maste)
Date: Mon Nov 2 19:01:31 2009
Subject: svn commit: r198817 - in stable/6/sys: . conf contrib/pf dev/aac
dev/cxgb
Message-ID: <200911021901.nA2J1K8b066728@svn.freebsd.org>
Author: emaste
Date: Mon Nov 2 19:01:20 2009
New Revision: 198817
URL: http://svn.freebsd.org/changeset/base/198817
Log:
MFC r197011:
Increase AAC_CMD_TIMEOUT from 30s to 120s to help avoid spurious
"COMMAND 0x........ TIMEOUT AFTER .. SECONDS" messages. Any commands
that get truly stuck will still trigger the warning and the hardware
health check, just a little bit later.
Modified:
stable/6/sys/ (props changed)
stable/6/sys/conf/ (props changed)
stable/6/sys/contrib/pf/ (props changed)
stable/6/sys/dev/aac/aacvar.h
stable/6/sys/dev/cxgb/ (props changed)
Modified: stable/6/sys/dev/aac/aacvar.h
==============================================================================
--- stable/6/sys/dev/aac/aacvar.h Mon Nov 2 18:51:24 2009 (r198816)
+++ stable/6/sys/dev/aac/aacvar.h Mon Nov 2 19:01:20 2009 (r198817)
@@ -88,7 +88,7 @@
/*
* Timeout for normal commands
*/
-#define AAC_CMD_TIMEOUT 30 /* seconds */
+#define AAC_CMD_TIMEOUT 120 /* seconds */
/*
* Rate at which we periodically check for timed out commands and kick the
From mav at FreeBSD.org Mon Nov 2 19:02:32 2009
From: mav at FreeBSD.org (Alexander Motin)
Date: Mon Nov 2 19:02:44 2009
Subject: svn commit: r198818 - in head/sys/dev/ata: . chipsets
Message-ID: <200911021902.nA2J2Vvb066782@svn.freebsd.org>
Author: mav
Date: Mon Nov 2 19:02:31 2009
New Revision: 198818
URL: http://svn.freebsd.org/changeset/base/198818
Log:
Add IDs for nVidia MCP65/77/79/89 SATA conntrollers.
Modified:
head/sys/dev/ata/ata-pci.h
head/sys/dev/ata/chipsets/ata-nvidia.c
Modified: head/sys/dev/ata/ata-pci.h
==============================================================================
--- head/sys/dev/ata/ata-pci.h Mon Nov 2 19:01:20 2009 (r198817)
+++ head/sys/dev/ata/ata-pci.h Mon Nov 2 19:02:31 2009 (r198818)
@@ -260,6 +260,15 @@ struct ata_pci_controller {
#define ATA_NFORCE_MCP61_S2 0x03f610de
#define ATA_NFORCE_MCP61_S3 0x03f710de
#define ATA_NFORCE_MCP65 0x044810de
+#define ATA_NFORCE_MCP65_A0 0x044c10de
+#define ATA_NFORCE_MCP65_A1 0x044d10de
+#define ATA_NFORCE_MCP65_A2 0x044e10de
+#define ATA_NFORCE_MCP65_A3 0x044f10de
+#define ATA_NFORCE_MCP65_A4 0x045c10de
+#define ATA_NFORCE_MCP65_A5 0x045d10de
+#define ATA_NFORCE_MCP65_A6 0x045e10de
+#define ATA_NFORCE_MCP65_A7 0x045f10de
+#define ATA_NFORCE_MCP67 0x056010de
#define ATA_NFORCE_MCP67_A0 0x055010de
#define ATA_NFORCE_MCP67_A1 0x055110de
#define ATA_NFORCE_MCP67_A2 0x055210de
@@ -273,7 +282,6 @@ struct ata_pci_controller {
#define ATA_NFORCE_MCP67_AA 0x055A10de
#define ATA_NFORCE_MCP67_AB 0x055B10de
#define ATA_NFORCE_MCP67_AC 0x058410de
-#define ATA_NFORCE_MCP67 0x056010de
#define ATA_NFORCE_MCP73 0x056c10de
#define ATA_NFORCE_MCP73_A0 0x07f010de
#define ATA_NFORCE_MCP73_A1 0x07f110de
@@ -288,6 +296,42 @@ struct ata_pci_controller {
#define ATA_NFORCE_MCP73_AA 0x07fa10de
#define ATA_NFORCE_MCP73_AB 0x07fb10de
#define ATA_NFORCE_MCP77 0x075910de
+#define ATA_NFORCE_MCP77_A0 0x0ad010de
+#define ATA_NFORCE_MCP77_A1 0x0ad110de
+#define ATA_NFORCE_MCP77_A2 0x0ad210de
+#define ATA_NFORCE_MCP77_A3 0x0ad310de
+#define ATA_NFORCE_MCP77_A4 0x0ad410de
+#define ATA_NFORCE_MCP77_A5 0x0ad510de
+#define ATA_NFORCE_MCP77_A6 0x0ad610de
+#define ATA_NFORCE_MCP77_A7 0x0ad710de
+#define ATA_NFORCE_MCP77_A8 0x0ad810de
+#define ATA_NFORCE_MCP77_A9 0x0ad910de
+#define ATA_NFORCE_MCP77_AA 0x0ada10de
+#define ATA_NFORCE_MCP77_AB 0x0adb10de
+#define ATA_NFORCE_MCP79_A0 0x0ab410de
+#define ATA_NFORCE_MCP79_A1 0x0ab510de
+#define ATA_NFORCE_MCP79_A2 0x0ab610de
+#define ATA_NFORCE_MCP79_A3 0x0ab710de
+#define ATA_NFORCE_MCP79_A4 0x0ab810de
+#define ATA_NFORCE_MCP79_A5 0x0ab910de
+#define ATA_NFORCE_MCP79_A6 0x0aba10de
+#define ATA_NFORCE_MCP79_A7 0x0abb10de
+#define ATA_NFORCE_MCP79_A8 0x0abc10de
+#define ATA_NFORCE_MCP79_A9 0x0abd10de
+#define ATA_NFORCE_MCP79_AA 0x0abe10de
+#define ATA_NFORCE_MCP79_AB 0x0abf10de
+#define ATA_NFORCE_MCP89_A0 0x0d8410de
+#define ATA_NFORCE_MCP89_A1 0x0d8510de
+#define ATA_NFORCE_MCP89_A2 0x0d8610de
+#define ATA_NFORCE_MCP89_A3 0x0d8710de
+#define ATA_NFORCE_MCP89_A4 0x0d8810de
+#define ATA_NFORCE_MCP89_A5 0x0d8910de
+#define ATA_NFORCE_MCP89_A6 0x0d8a10de
+#define ATA_NFORCE_MCP89_A7 0x0d8b10de
+#define ATA_NFORCE_MCP89_A8 0x0d8c10de
+#define ATA_NFORCE_MCP89_A9 0x0d8d10de
+#define ATA_NFORCE_MCP89_AA 0x0d8e10de
+#define ATA_NFORCE_MCP89_AB 0x0d8f10de
#define ATA_PROMISE_ID 0x105a
#define ATA_PDC20246 0x4d33105a
Modified: head/sys/dev/ata/chipsets/ata-nvidia.c
==============================================================================
--- head/sys/dev/ata/chipsets/ata-nvidia.c Mon Nov 2 19:01:20 2009 (r198817)
+++ head/sys/dev/ata/chipsets/ata-nvidia.c Mon Nov 2 19:02:31 2009 (r198818)
@@ -97,6 +97,14 @@ ata_nvidia_probe(device_t dev)
{ ATA_NFORCE_MCP61_S2, 0, NV4|NVQ, 0, ATA_SA300, "nForce MCP61" },
{ ATA_NFORCE_MCP61_S3, 0, NV4|NVQ, 0, ATA_SA300, "nForce MCP61" },
{ ATA_NFORCE_MCP65, 0, 0, 0, ATA_UDMA6, "nForce MCP65" },
+ { ATA_NFORCE_MCP65_A0, 0, NVAHCI, 0, ATA_SA300, "nForce MCP65" },
+ { ATA_NFORCE_MCP65_A1, 0, NVAHCI, 0, ATA_SA300, "nForce MCP65" },
+ { ATA_NFORCE_MCP65_A2, 0, NVAHCI, 0, ATA_SA300, "nForce MCP65" },
+ { ATA_NFORCE_MCP65_A3, 0, NVAHCI, 0, ATA_SA300, "nForce MCP65" },
+ { ATA_NFORCE_MCP65_A4, 0, NVAHCI, 0, ATA_SA300, "nForce MCP65" },
+ { ATA_NFORCE_MCP65_A5, 0, NVAHCI, 0, ATA_SA300, "nForce MCP65" },
+ { ATA_NFORCE_MCP65_A6, 0, NVAHCI, 0, ATA_SA300, "nForce MCP65" },
+ { ATA_NFORCE_MCP65_A7, 0, NVAHCI, 0, ATA_SA300, "nForce MCP65" },
{ ATA_NFORCE_MCP67, 0, 0, 0, ATA_UDMA6, "nForce MCP67" },
{ ATA_NFORCE_MCP67_A0, 0, NVAHCI, 0, ATA_SA300, "nForce MCP67" },
{ ATA_NFORCE_MCP67_A1, 0, NVAHCI, 0, ATA_SA300, "nForce MCP67" },
@@ -125,6 +133,42 @@ ata_nvidia_probe(device_t dev)
{ ATA_NFORCE_MCP73_AA, 0, NVAHCI, 0, ATA_SA300, "nForce MCP73" },
{ ATA_NFORCE_MCP73_AB, 0, NVAHCI, 0, ATA_SA300, "nForce MCP73" },
{ ATA_NFORCE_MCP77, 0, 0, 0, ATA_UDMA6, "nForce MCP77" },
+ { ATA_NFORCE_MCP77_A0, 0, NVAHCI, 0, ATA_SA300, "nForce MCP77" },
+ { ATA_NFORCE_MCP77_A1, 0, NVAHCI, 0, ATA_SA300, "nForce MCP77" },
+ { ATA_NFORCE_MCP77_A2, 0, NVAHCI, 0, ATA_SA300, "nForce MCP77" },
+ { ATA_NFORCE_MCP77_A3, 0, NVAHCI, 0, ATA_SA300, "nForce MCP77" },
+ { ATA_NFORCE_MCP77_A4, 0, NVAHCI, 0, ATA_SA300, "nForce MCP77" },
+ { ATA_NFORCE_MCP77_A5, 0, NVAHCI, 0, ATA_SA300, "nForce MCP77" },
+ { ATA_NFORCE_MCP77_A6, 0, NVAHCI, 0, ATA_SA300, "nForce MCP77" },
+ { ATA_NFORCE_MCP77_A7, 0, NVAHCI, 0, ATA_SA300, "nForce MCP77" },
+ { ATA_NFORCE_MCP77_A8, 0, NVAHCI, 0, ATA_SA300, "nForce MCP77" },
+ { ATA_NFORCE_MCP77_A9, 0, NVAHCI, 0, ATA_SA300, "nForce MCP77" },
+ { ATA_NFORCE_MCP77_AA, 0, NVAHCI, 0, ATA_SA300, "nForce MCP77" },
+ { ATA_NFORCE_MCP77_AB, 0, NVAHCI, 0, ATA_SA300, "nForce MCP77" },
+ { ATA_NFORCE_MCP79_A0, 0, NVAHCI, 0, ATA_SA300, "nForce MCP79" },
+ { ATA_NFORCE_MCP79_A1, 0, NVAHCI, 0, ATA_SA300, "nForce MCP79" },
+ { ATA_NFORCE_MCP79_A2, 0, NVAHCI, 0, ATA_SA300, "nForce MCP79" },
+ { ATA_NFORCE_MCP79_A3, 0, NVAHCI, 0, ATA_SA300, "nForce MCP79" },
+ { ATA_NFORCE_MCP79_A4, 0, NVAHCI, 0, ATA_SA300, "nForce MCP79" },
+ { ATA_NFORCE_MCP79_A5, 0, NVAHCI, 0, ATA_SA300, "nForce MCP79" },
+ { ATA_NFORCE_MCP79_A6, 0, NVAHCI, 0, ATA_SA300, "nForce MCP79" },
+ { ATA_NFORCE_MCP79_A7, 0, NVAHCI, 0, ATA_SA300, "nForce MCP79" },
+ { ATA_NFORCE_MCP79_A8, 0, NVAHCI, 0, ATA_SA300, "nForce MCP79" },
+ { ATA_NFORCE_MCP79_A9, 0, NVAHCI, 0, ATA_SA300, "nForce MCP79" },
+ { ATA_NFORCE_MCP79_AA, 0, NVAHCI, 0, ATA_SA300, "nForce MCP79" },
+ { ATA_NFORCE_MCP79_AB, 0, NVAHCI, 0, ATA_SA300, "nForce MCP79" },
+ { ATA_NFORCE_MCP89_A0, 0, NVAHCI, 0, ATA_SA300, "nForce MCP89" },
+ { ATA_NFORCE_MCP89_A1, 0, NVAHCI, 0, ATA_SA300, "nForce MCP89" },
+ { ATA_NFORCE_MCP89_A2, 0, NVAHCI, 0, ATA_SA300, "nForce MCP89" },
+ { ATA_NFORCE_MCP89_A3, 0, NVAHCI, 0, ATA_SA300, "nForce MCP89" },
+ { ATA_NFORCE_MCP89_A4, 0, NVAHCI, 0, ATA_SA300, "nForce MCP89" },
+ { ATA_NFORCE_MCP89_A5, 0, NVAHCI, 0, ATA_SA300, "nForce MCP89" },
+ { ATA_NFORCE_MCP89_A6, 0, NVAHCI, 0, ATA_SA300, "nForce MCP89" },
+ { ATA_NFORCE_MCP89_A7, 0, NVAHCI, 0, ATA_SA300, "nForce MCP89" },
+ { ATA_NFORCE_MCP89_A8, 0, NVAHCI, 0, ATA_SA300, "nForce MCP89" },
+ { ATA_NFORCE_MCP89_A9, 0, NVAHCI, 0, ATA_SA300, "nForce MCP89" },
+ { ATA_NFORCE_MCP89_AA, 0, NVAHCI, 0, ATA_SA300, "nForce MCP89" },
+ { ATA_NFORCE_MCP89_AB, 0, NVAHCI, 0, ATA_SA300, "nForce MCP89" },
{ 0, 0, 0, 0, 0, 0}} ;
if (pci_get_vendor(dev) != ATA_NVIDIA_ID)
From rpaulo at FreeBSD.org Mon Nov 2 19:13:13 2009
From: rpaulo at FreeBSD.org (Rui Paulo)
Date: Mon Nov 2 19:13:24 2009
Subject: svn commit: r198819 - head/sys/compat/ndis
Message-ID: <200911021913.nA2JDDA8067089@svn.freebsd.org>
Author: rpaulo
Date: Mon Nov 2 19:13:12 2009
New Revision: 198819
URL: http://svn.freebsd.org/changeset/base/198819
Log:
Revert a functional change that snuck in.
Modified:
head/sys/compat/ndis/subr_ndis.c
Modified: head/sys/compat/ndis/subr_ndis.c
==============================================================================
--- head/sys/compat/ndis/subr_ndis.c Mon Nov 2 19:02:31 2009 (r198818)
+++ head/sys/compat/ndis/subr_ndis.c Mon Nov 2 19:13:12 2009 (r198819)
@@ -1246,7 +1246,7 @@ NdisMQueryAdapterResources(status, adapt
{
ndis_miniport_block *block;
struct ndis_softc *sc;
- uint32_t rsclen;
+ int rsclen;
block = (ndis_miniport_block *)adapter;
sc = device_get_softc(block->nmb_physdeviceobj->do_devext);
From jhb at FreeBSD.org Mon Nov 2 20:18:52 2009
From: jhb at FreeBSD.org (John Baldwin)
Date: Mon Nov 2 20:18:58 2009
Subject: svn commit: r198820 - head/sbin/ddb
Message-ID: <200911022018.nA2KIp6Q068433@svn.freebsd.org>
Author: jhb
Date: Mon Nov 2 20:18:50 2009
New Revision: 198820
URL: http://svn.freebsd.org/changeset/base/198820
Log:
Ensure 'kvm' is always initialized. If "-M" was not specified and the
garbage value on the stack was not zero, then 'ddb capture' would try to
use the garbage value as a kvm_t pointer.
MFC after: 1 week
Modified:
head/sbin/ddb/ddb_capture.c
Modified: head/sbin/ddb/ddb_capture.c
==============================================================================
--- head/sbin/ddb/ddb_capture.c Mon Nov 2 19:13:12 2009 (r198819)
+++ head/sbin/ddb/ddb_capture.c Mon Nov 2 20:18:50 2009 (r198820)
@@ -204,6 +204,7 @@ ddb_capture(int argc, char *argv[])
mflag = NULL;
nflag = NULL;
+ kvm = NULL;
while ((ch = getopt(argc, argv, "M:N:")) != -1) {
switch (ch) {
case 'M':
From kostikbel at gmail.com Mon Nov 2 20:34:41 2009
From: kostikbel at gmail.com (Kostik Belousov)
Date: Mon Nov 2 20:34:47 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To:
References: <20091101011212.GG1293@hoeg.nl>
<20091102100435.GA67211@walton.maths.tcd.ie>
<20091102102404.GP1293@hoeg.nl>
<20091102.084616.-1258100553.imp@bsdimp.com>
<20091102155414.GR1293@hoeg.nl>
Message-ID: <20091102203419.GV2147@deviant.kiev.zoral.com.ua>
On Mon, Nov 02, 2009 at 10:08:17AM -0800, Marcel Moolenaar wrote:
> For a change that does change the ABI: revision 198506
> tcsh(1) dumps core with a sig 11...
Can you provide some details ? Which architecture is it ?
What is the backtrace ? What is the ktrace before SIGSEGV ?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091102/50931b2a/attachment.pgp
From simon at FreeBSD.org Mon Nov 2 20:37:50 2009
From: simon at FreeBSD.org (Simon L. Nielsen)
Date: Mon Nov 2 20:37:57 2009
Subject: svn commit: r198821 - svnadmin/hooks/scripts
Message-ID: <200911022037.nA2Kboga068930@svn.freebsd.org>
Author: simon
Date: Mon Nov 2 20:37:49 2009
New Revision: 198821
URL: http://svn.freebsd.org/changeset/base/198821
Log:
Change the handling of directory property changes in the svn mailer
script:
- Removes all directories that have only prop-changes from the subject
line (unless there are only prop-changes in the commit).
- Move directory prop-changes to a separate category at the end of the
change listing.
This should hopefully reduce the problem mergeinfo in sys/contrib etc.
"cluttering up" commit mails, and should also make it easier to spot
when there is mergeinfo missing (or misplaced) in a MFC.
Submitted by: mlaier (also most of the commit message)
Reviewed by: peter (the general idea)
Modified:
svnadmin/hooks/scripts/mailer.py
Directory Properties:
Modified: svnadmin/hooks/scripts/mailer.py
==============================================================================
--- svnadmin/hooks/scripts/mailer.py Mon Nov 2 20:18:50 2009 (r198820)
+++ svnadmin/hooks/scripts/mailer.py Mon Nov 2 20:37:49 2009 (r198821)
@@ -370,9 +370,14 @@ class Commit(Messenger):
# figure out the changed directories
dirs = { }
+ pdirs = { }
for path, change in self.changelist:
if change.item_kind == svn.core.svn_node_dir:
- dirs[path] = None
+ # do not include dirs that have only prop changes
+ if change.prop_changes:
+ pdirs[path] = None
+ else:
+ dirs[path] = None
else:
idx = string.rfind(path, '/')
if idx == -1:
@@ -380,7 +385,10 @@ class Commit(Messenger):
else:
dirs[path[:idx]] = None
- dirlist = dirs.keys()
+ if len(dirs) == 0:
+ dirlist = pdirs.keys()
+ else:
+ dirlist = dirs.keys()
commondir, dirlist = get_commondir(dirlist)
@@ -1029,6 +1037,7 @@ class TextCommitRenderer:
w = self.output.write
w(header + ':\n')
+ ps = ''
for d in data_list:
if d.is_dir:
is_dir = '/'
@@ -1037,11 +1046,13 @@ class TextCommitRenderer:
if d.props_changed:
if d.text_changed:
props = ' (contents, props changed)'
+ w(' %s%s%s\n' % (d.path, is_dir, props))
else:
props = ' (props changed)'
+ ps = ('%s %s%s%s\n' % (ps, d.path, is_dir, props))
else:
props = ''
- w(' %s%s%s\n' % (d.path, is_dir, props))
+ w(' %s%s%s\n' % (d.path, is_dir, props))
if d.copied:
if is_dir:
text = ''
@@ -1051,6 +1062,7 @@ class TextCommitRenderer:
text = ' unchanged'
w(' - copied%s from r%d, %s%s\n'
% (text, d.base_rev, d.base_path, is_dir))
+ w('Directory Properties:\n%s' % (ps))
def _render_diffs(self, diffs, section_header):
"""Render diffs. Write the SECTION_HEADER if there are actually
From xcllnt at mac.com Mon Nov 2 20:45:42 2009
From: xcllnt at mac.com (Marcel Moolenaar)
Date: Mon Nov 2 20:45:49 2009
Subject: svn commit: r198706 - head/sys/sys
In-Reply-To: <20091102203419.GV2147@deviant.kiev.zoral.com.ua>
References: <20091101011212.GG1293@hoeg.nl>
<20091102100435.GA67211@walton.maths.tcd.ie>
<20091102102404.GP1293@hoeg.nl>
<20091102.084616.-1258100553.imp@bsdimp.com>
<20091102155414.GR1293@hoeg.nl>
<20091102203419.GV2147@deviant.kiev.zoral.com.ua>
Message-ID: <5537A11F-92AC-4D73-BBE7-297A1575BE1B@mac.com>
On Nov 2, 2009, at 12:34 PM, Kostik Belousov wrote:
> On Mon, Nov 02, 2009 at 10:08:17AM -0800, Marcel Moolenaar wrote:
>> For a change that does change the ABI: revision 198506
>> tcsh(1) dumps core with a sig 11...
>
> Can you provide some details ? Which architecture is it ?
> What is the backtrace ? What is the ktrace before SIGSEGV ?
I'm working on it. I see it on ia64, so the root cause may be
an ia64-specific bug. The sig 11 happens when csh calls
sigsuspend:
(gdb) l *$b0
0x20000000000483a0 is in pjwait (/nfs/freebsd/base/head/bin/csh/../../
contrib/tcsh/sh.proc.c:513).
508 while ((fp = (fp->p_friends)) != pp);
509 if ((jobflags & PRUNNING) == 0)
510 break;
511 jobdebug_xprintf(("%d starting to sigsuspend for SIGCHLD on %d\n",
512 getpid(), fp->p_procid));
513 sigsuspend(&pause_mask);
514 }
515 cleanup_until(&oset);
516 jobdebug_xprintf(("%d returned from sigsuspend loop\n", getpid
()));
517 #ifdef BSDJOBS
(gdb)
FYI,
--
Marcel Moolenaar
xcllnt@mac.com
From mjacob at FreeBSD.org Mon Nov 2 21:22:31 2009
From: mjacob at FreeBSD.org (Matt Jacob)
Date: Mon Nov 2 21:22:38 2009
Subject: svn commit: r198822 - head/sys/dev/isp
Message-ID: <200911022122.nA2LMUtt070116@svn.freebsd.org>
Author: mjacob
Date: Mon Nov 2 21:22:30 2009
New Revision: 198822
URL: http://svn.freebsd.org/changeset/base/198822
Log:
Unbreak SBus cards which have been broken (apparently) for a while.
Most of the pieces came from Marius- correct settings for channels
and resource management. The one piece missing was that you cannot
for SBus cards replace 32 bit operations with A64 operations- not
supported.
Submitted by: marius
MFC after: 3 days
Modified:
head/sys/dev/isp/isp_sbus.c
Directory Properties:
Modified: head/sys/dev/isp/isp_sbus.c
==============================================================================
--- head/sys/dev/isp/isp_sbus.c Mon Nov 2 20:37:49 2009 (r198821)
+++ head/sys/dev/isp/isp_sbus.c Mon Nov 2 21:22:30 2009 (r198822)
@@ -193,6 +193,8 @@ isp_sbus_attach(device_t dev)
isp->isp_param = &sbs->sbus_param;
isp->isp_osinfo.pc.ptr = &sbs->sbus_spi;
isp->isp_revision = 0; /* XXX */
+ isp->isp_dev = dev;
+ isp->isp_nchan = 1;
ISP_SET_PC(isp, 0, role, role);
/*
@@ -316,18 +318,16 @@ isp_sbus_attach(device_t dev)
goto bad;
}
isp_init(isp);
- if (role != ISP_ROLE_NONE && isp->isp_state != ISP_INITSTATE) {
- isp_uninit(isp);
- ISP_UNLOCK(isp);
- goto bad;
+ if (isp->isp_state == ISP_INITSTATE) {
+ isp->isp_state = ISP_RUNSTATE;
}
- isp_attach(isp);
- if (role != ISP_ROLE_NONE && isp->isp_state != ISP_RUNSTATE) {
+ ISP_UNLOCK(isp);
+ if (isp_attach(isp)) {
+ ISP_LOCK(isp);
isp_uninit(isp);
ISP_UNLOCK(isp);
goto bad;
}
- ISP_UNLOCK(isp);
return (0);
bad:
@@ -345,13 +345,10 @@ bad:
}
if (regs) {
- (void) bus_release_resource(dev, 0, 0, regs);
+ (void) bus_release_resource(dev, SYS_RES_MEMORY, 0, regs);
}
if (sbs) {
- if (sbs->sbus_isp.isp_param) {
- free(sbs->sbus_isp.isp_param, M_DEVBUF);
- }
free(sbs, M_DEVBUF);
}
return (ENXIO);
@@ -584,13 +581,6 @@ dma2(void *arg, bus_dma_segment_t *dm_se
isp = mp->isp;
rq = mp->rq;
if (nseg) {
- if (sizeof (bus_addr_t) > 4) {
- if (rq->req_header.rqs_entry_type == RQSTYPE_T2RQS) {
- rq->req_header.rqs_entry_type = RQSTYPE_T3RQS;
- } else if (rq->req_header.rqs_entry_type == RQSTYPE_REQUEST) {
- rq->req_header.rqs_entry_type = RQSTYPE_A64;
- }
- }
if ((csio->ccb_h.flags & CAM_DIR_MASK) == CAM_DIR_IN) {
bus_dmamap_sync(isp->isp_osinfo.dmat, PISP_PCMD(csio)->dmap, BUS_DMASYNC_PREREAD);
ddir = ISP_FROM_DEVICE;
From edwin at FreeBSD.org Mon Nov 2 21:39:45 2009
From: edwin at FreeBSD.org (Edwin Groothuis)
Date: Mon Nov 2 21:39:52 2009
Subject: svn commit: r198823 - vendor/tzdata/dist
Message-ID: <200911022139.nA2LdjOg070536@svn.freebsd.org>
Author: edwin
Date: Mon Nov 2 21:39:45 2009
New Revision: 198823
URL: http://svn.freebsd.org/changeset/base/198823
Log:
Vendor import of tzdata2009q:
- New region: Asia/Novokuznetsk
- Kemerovo oblast' (Kemerovo region) in Russia will change current
time zone on 29 March 2010
- Add historical data for Hongkong 1941 - 1980
- Syria will go to winter time in the last weekend of October 2009.
Obtained from: ftp://elsie.nci.nih.gov/pub/
Modified:
vendor/tzdata/dist/asia
vendor/tzdata/dist/europe
vendor/tzdata/dist/zone.tab
Modified: vendor/tzdata/dist/asia
==============================================================================
--- vendor/tzdata/dist/asia Mon Nov 2 21:22:30 2009 (r198822)
+++ vendor/tzdata/dist/asia Mon Nov 2 21:39:45 2009 (r198823)
@@ -1,5 +1,4 @@
-#
-# @(#)asia 8.42
+# @(#)asia 8.44
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
@@ -369,14 +368,84 @@ Zone Asia/Kashgar 5:03:56 - LMT 1928 # o
5:00 - KAST 1980 May
8:00 PRC C%sT
+
+# From Lee Yiu Chung (2009-10-24):
+# I found there are some mistakes for the historial DST rule for Hong
+# Kong. Accoring to the DST record from Hong Kong Observatory (actually,
+# it is not [an] observatory, but the official meteorological agency of HK,
+# and also serves as the official timing agency), there are some missing
+# and incorrect rules. Although the exact switch over time is missing, I
+# think 3:30 is correct. The official DST record for Hong Kong can be
+# obtained from
+#
+# http://www.hko.gov.hk/gts/time/Summertime.htm
+# .
+
+# From Arthur David Olson (2009-10-28):
+# Here are the dates given at
+#
+# http://www.hko.gov.hk/gts/time/Summertime.htm
+#
+# as of 2009-10-28:
+# Year Period
+# 1941 1 Apr to 30 Sep
+# 1942 Whole year
+# 1943 Whole year
+# 1944 Whole year
+# 1945 Whole year
+# 1946 20 Apr to 1 Dec
+# 1947 13 Apr to 30 Dec
+# 1948 2 May to 31 Oct
+# 1949 3 Apr to 30 Oct
+# 1950 2 Apr to 29 Oct
+# 1951 1 Apr to 28 Oct
+# 1952 6 Apr to 25 Oct
+# 1953 5 Apr to 1 Nov
+# 1954 21 Mar to 31 Oct
+# 1955 20 Mar to 6 Nov
+# 1956 18 Mar to 4 Nov
+# 1957 24 Mar to 3 Nov
+# 1958 23 Mar to 2 Nov
+# 1959 22 Mar to 1 Nov
+# 1960 20 Mar to 6 Nov
+# 1961 19 Mar to 5 Nov
+# 1962 18 Mar to 4 Nov
+# 1963 24 Mar to 3 Nov
+# 1964 22 Mar to 1 Nov
+# 1965 18 Apr to 17 Oct
+# 1966 17 Apr to 16 Oct
+# 1967 16 Apr to 22 Oct
+# 1968 21 Apr to 20 Oct
+# 1969 20 Apr to 19 Oct
+# 1970 19 Apr to 18 Oct
+# 1971 18 Apr to 17 Oct
+# 1972 16 Apr to 22 Oct
+# 1973 22 Apr to 21 Oct
+# 1973/74 30 Dec 73 to 20 Oct 74
+# 1975 20 Apr to 19 Oct
+# 1976 18 Apr to 17 Oct
+# 1977 Nil
+# 1978 Nil
+# 1979 13 May to 21 Oct
+# 1980 to Now Nil
+# The page does not give start or end times of day.
+# The page does not give a start date for 1942.
+# The page does not givw an end date for 1945.
+# The Japanese occupation of Hong Kong began on 1941-12-25.
+# The Japanese surrender of Hong Kong was signed 1945-09-15.
+# For lack of anything better, use start of those days as the transition times.
+
# Hong Kong (Xianggang)
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
+Rule HK 1941 only - Apr 1 3:30 1:00 S
+Rule HK 1941 only - Sep 30 3:30 0 -
Rule HK 1946 only - Apr 20 3:30 1:00 S
Rule HK 1946 only - Dec 1 3:30 0 -
Rule HK 1947 only - Apr 13 3:30 1:00 S
Rule HK 1947 only - Dec 30 3:30 0 -
Rule HK 1948 only - May 2 3:30 1:00 S
-Rule HK 1948 1952 - Oct lastSun 3:30 0 -
+Rule HK 1948 1951 - Oct lastSun 3:30 0 -
+Rule HK 1952 only - Oct 25 3:30 0 -
Rule HK 1949 1953 - Apr Sun>=1 3:30 1:00 S
Rule HK 1953 only - Nov 1 3:30 0 -
Rule HK 1954 1964 - Mar Sun>=18 3:30 1:00 S
@@ -384,13 +453,15 @@ Rule HK 1954 only - Oct 31 3:30 0 -
Rule HK 1955 1964 - Nov Sun>=1 3:30 0 -
Rule HK 1965 1977 - Apr Sun>=16 3:30 1:00 S
Rule HK 1965 1977 - Oct Sun>=16 3:30 0 -
-Rule HK 1979 1980 - May Sun>=8 3:30 1:00 S
-Rule HK 1979 1980 - Oct Sun>=16 3:30 0 -
+Rule HK 1973 only - Dec 30 3:30 1:00 S
+Rule HK 1979 only - May Sun>=8 3:30 1:00 S
+Rule HK 1979 only - Oct Sun>=16 3:30 0 -
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Hong_Kong 7:36:36 - LMT 1904 Oct 30
+ 8:00 HK HK%sT 1941 Dec 25
+ 9:00 - JST 1945 Sep 15
8:00 HK HK%sT
-
###############################################################################
# Taiwan
@@ -2236,9 +2307,23 @@ Rule Syria 2007 only - Nov Fri>=1 0:00
# http://www.timeanddate.com/news/time/syria-dst-starts-march-27-2009.html
#
+# From Steffen Thorsen (2009-10-27):
+# The Syrian Arab News Network on 2009-09-29 reported that Syria will
+# revert back to winter (standard) time on midnight between Thursday
+# 2009-10-29 and Friday 2009-10-30:
+#
+# http://www.sana.sy/ara/2/2009/09/29/247012.htm (Arabic)
+#
+
+# From Arthur David Olson (2009-10-28):
+# We'll see if future DST switching times turn out to be end of the last
+# Thursday of the month or the start of the last Friday of the month or
+# something else. For now, use the start of the last Friday.
+
Rule Syria 2008 only - Apr Fri>=1 0:00 1:00 S
-Rule Syria 2008 max - Nov 1 0:00 0 -
+Rule Syria 2008 only - Nov 1 0:00 0 -
Rule Syria 2009 max - Mar lastFri 0:00 1:00 S
+Rule Syria 2009 max - Oct lastFri 0:00 0 -
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Damascus 2:25:12 - LMT 1920 # Dimashq
Modified: vendor/tzdata/dist/europe
==============================================================================
--- vendor/tzdata/dist/europe Mon Nov 2 21:22:30 2009 (r198822)
+++ vendor/tzdata/dist/europe Mon Nov 2 21:39:45 2009 (r198823)
@@ -1,5 +1,5 @@
#
-# @(#)europe 8.22
+# @(#)europe 8.24
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
@@ -2072,9 +2072,43 @@ Zone Asia/Novosibirsk 5:31:40 - LMT 191
6:00 Russia NOV%sT 1992 Jan 19 2:00s
7:00 Russia NOV%sT 1993 May 23 # say Shanks & P.
6:00 Russia NOV%sT
+
+# From Alexander Krivenyshev (2009-10-13):
+# Kemerovo oblast' (Kemerovo region) in Russia will change current time zone on
+# March 28, 2010:
+# from current Russia Zone 6 - Krasnoyarsk Time Zone (KRA) UTC +0700
+# to Russia Zone 5 - Novosibirsk Time Zone (NOV) UTC +0600
+#
+# This is according to Government of Russia decree # 740, on September
+# 14, 2009 "Application in the territory of the Kemerovo region the Fifth
+# time zone." ("Russia Zone 5" or old "USSR Zone 5" is GMT +0600)
+#
+# Russian Government web site (Russian language)
+#
+# http://www.government.ru/content/governmentactivity/rfgovernmentdecisions/archive/2009/09/14/991633.htm
+#
+# or Russian-English translation by WorldTimeZone.com with reference
+# map to local region and new Russia Time Zone map after March 28, 2010
+#
+# http://www.worldtimezone.com/dst_news/dst_news_russia03.html
+#
+#
+# Thus, when Russia will switch to DST on the night of March 28, 2010
+# Kemerovo region (Kemerovo oblast') will not change the clock.
+#
+# As a result, Kemerovo oblast' will be in the same time zone as
+# Novosibirsk, Omsk, Tomsk, Barnaul and Altai Republic.
+
+Zone Asia/Novokuznetsk 5:48:48 - NMT 1920 Jan 6
+ 6:00 - KRAT 1930 Jun 21 # Krasnoyarsk Time
+ 7:00 Russia KRA%sT 1991 Mar 31 2:00s
+ 6:00 Russia KRA%sT 1992 Jan 19 2:00s
+ 7:00 Russia KRA%sT 2010 Mar 28 2:00s
+ 6:00 Russia NOV%sT # Novosibirsk/Novokuznetsk Time
+
#
# From Oscar van Vlijmen (2001-08-25): [This region consists of]
-# Kemerovskaya oblast', Krasnoyarskij kraj,
+# Krasnoyarskij kraj,
# Tajmyrskij (Dolgano-Nenetskij) avtonomnyj okrug,
# Respublika Tuva, Respublika Khakasiya, Evenkijskij avtonomnyj okrug.
Zone Asia/Krasnoyarsk 6:11:20 - LMT 1920 Jan 6
Modified: vendor/tzdata/dist/zone.tab
==============================================================================
--- vendor/tzdata/dist/zone.tab Mon Nov 2 21:22:30 2009 (r198822)
+++ vendor/tzdata/dist/zone.tab Mon Nov 2 21:39:45 2009 (r198823)
@@ -1,5 +1,5 @@
#
-# @(#)zone.tab 8.28
+# @(#)zone.tab 8.29
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
#
@@ -330,6 +330,7 @@ RU +5312+05009 Europe/Samara Moscow+01 -
RU +5651+06036 Asia/Yekaterinburg Moscow+02 - Urals
RU +5500+07324 Asia/Omsk Moscow+03 - west Siberia
RU +5502+08255 Asia/Novosibirsk Moscow+03 - Novosibirsk
+RU +5345+08707 Asia/Novokuznetsk Moscow+03 - Novokuznetsk
RU +5601+09250 Asia/Krasnoyarsk Moscow+04 - Yenisei River
RU +5216+10420 Asia/Irkutsk Moscow+05 - Lake Baikal
RU +6200+12940 Asia/Yakutsk Moscow+06 - Lena River
From edwin at FreeBSD.org Mon Nov 2 21:40:50 2009
From: edwin at FreeBSD.org (Edwin Groothuis)
Date: Mon Nov 2 21:41:02 2009
Subject: svn commit: r198824 - vendor/tzdata/tzdata2009q
Message-ID: <200911022140.nA2LeoZC070614@svn.freebsd.org>
Author: edwin
Date: Mon Nov 2 21:40:50 2009
New Revision: 198824
URL: http://svn.freebsd.org/changeset/base/198824
Log:
Tag of tzdata2009q
Added:
vendor/tzdata/tzdata2009q/
- copied from r198823, vendor/tzdata/dist/
From edwin at FreeBSD.org Mon Nov 2 21:44:10 2009
From: edwin at FreeBSD.org (Edwin Groothuis)
Date: Mon Nov 2 21:44:17 2009
Subject: svn commit: r198825 - head/share/zoneinfo
Message-ID: <200911022144.nA2LiAIx070736@svn.freebsd.org>
Author: edwin
Date: Mon Nov 2 21:44:10 2009
New Revision: 198825
URL: http://svn.freebsd.org/changeset/base/198825
Log:
MFV of tzdata2009q:
- New region: Asia/Novokuznetsk
- Kemerovo oblast' (Kemerovo region) in Russia will change current
time zone on 29 March 2010
- Add historical data for Hongkong 1941 - 1980
- Syria will go to winter time in the last weekend of October 2009.
MFC after: 2 days
Modified:
head/share/zoneinfo/asia
head/share/zoneinfo/europe
head/share/zoneinfo/zone.tab
Directory Properties:
head/share/zoneinfo/ (props changed)
Modified: head/share/zoneinfo/asia
==============================================================================
--- head/share/zoneinfo/asia Mon Nov 2 21:40:50 2009 (r198824)
+++ head/share/zoneinfo/asia Mon Nov 2 21:44:10 2009 (r198825)
@@ -1,5 +1,4 @@
-#
-# @(#)asia 8.42
+# @(#)asia 8.44
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
@@ -369,14 +368,84 @@ Zone Asia/Kashgar 5:03:56 - LMT 1928 # o
5:00 - KAST 1980 May
8:00 PRC C%sT
+
+# From Lee Yiu Chung (2009-10-24):
+# I found there are some mistakes for the historial DST rule for Hong
+# Kong. Accoring to the DST record from Hong Kong Observatory (actually,
+# it is not [an] observatory, but the official meteorological agency of HK,
+# and also serves as the official timing agency), there are some missing
+# and incorrect rules. Although the exact switch over time is missing, I
+# think 3:30 is correct. The official DST record for Hong Kong can be
+# obtained from
+#
+# http://www.hko.gov.hk/gts/time/Summertime.htm
+# .
+
+# From Arthur David Olson (2009-10-28):
+# Here are the dates given at
+#
+# http://www.hko.gov.hk/gts/time/Summertime.htm
+#
+# as of 2009-10-28:
+# Year Period
+# 1941 1 Apr to 30 Sep
+# 1942 Whole year
+# 1943 Whole year
+# 1944 Whole year
+# 1945 Whole year
+# 1946 20 Apr to 1 Dec
+# 1947 13 Apr to 30 Dec
+# 1948 2 May to 31 Oct
+# 1949 3 Apr to 30 Oct
+# 1950 2 Apr to 29 Oct
+# 1951 1 Apr to 28 Oct
+# 1952 6 Apr to 25 Oct
+# 1953 5 Apr to 1 Nov
+# 1954 21 Mar to 31 Oct
+# 1955 20 Mar to 6 Nov
+# 1956 18 Mar to 4 Nov
+# 1957 24 Mar to 3 Nov
+# 1958 23 Mar to 2 Nov
+# 1959 22 Mar to 1 Nov
+# 1960 20 Mar to 6 Nov
+# 1961 19 Mar to 5 Nov
+# 1962 18 Mar to 4 Nov
+# 1963 24 Mar to 3 Nov
+# 1964 22 Mar to 1 Nov
+# 1965 18 Apr to 17 Oct
+# 1966 17 Apr to 16 Oct
+# 1967 16 Apr to 22 Oct
+# 1968 21 Apr to 20 Oct
+# 1969 20 Apr to 19 Oct
+# 1970 19 Apr to 18 Oct
+# 1971 18 Apr to 17 Oct
+# 1972 16 Apr to 22 Oct
+# 1973 22 Apr to 21 Oct
+# 1973/74 30 Dec 73 to 20 Oct 74
+# 1975 20 Apr to 19 Oct
+# 1976 18 Apr to 17 Oct
+# 1977 Nil
+# 1978 Nil
+# 1979 13 May to 21 Oct
+# 1980 to Now Nil
+# The page does not give start or end times of day.
+# The page does not give a start date for 1942.
+# The page does not givw an end date for 1945.
+# The Japanese occupation of Hong Kong began on 1941-12-25.
+# The Japanese surrender of Hong Kong was signed 1945-09-15.
+# For lack of anything better, use start of those days as the transition times.
+
# Hong Kong (Xianggang)
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
+Rule HK 1941 only - Apr 1 3:30 1:00 S
+Rule HK 1941 only - Sep 30 3:30 0 -
Rule HK 1946 only - Apr 20 3:30 1:00 S
Rule HK 1946 only - Dec 1 3:30 0 -
Rule HK 1947 only - Apr 13 3:30 1:00 S
Rule HK 1947 only - Dec 30 3:30 0 -
Rule HK 1948 only - May 2 3:30 1:00 S
-Rule HK 1948 1952 - Oct lastSun 3:30 0 -
+Rule HK 1948 1951 - Oct lastSun 3:30 0 -
+Rule HK 1952 only - Oct 25 3:30 0 -
Rule HK 1949 1953 - Apr Sun>=1 3:30 1:00 S
Rule HK 1953 only - Nov 1 3:30 0 -
Rule HK 1954 1964 - Mar Sun>=18 3:30 1:00 S
@@ -384,13 +453,15 @@ Rule HK 1954 only - Oct 31 3:30 0 -
Rule HK 1955 1964 - Nov Sun>=1 3:30 0 -
Rule HK 1965 1977 - Apr Sun>=16 3:30 1:00 S
Rule HK 1965 1977 - Oct Sun>=16 3:30 0 -
-Rule HK 1979 1980 - May Sun>=8 3:30 1:00 S
-Rule HK 1979 1980 - Oct Sun>=16 3:30 0 -
+Rule HK 1973 only - Dec 30 3:30 1:00 S
+Rule HK 1979 only - May Sun>=8 3:30 1:00 S
+Rule HK 1979 only - Oct Sun>=16 3:30 0 -
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Hong_Kong 7:36:36 - LMT 1904 Oct 30
+ 8:00 HK HK%sT 1941 Dec 25
+ 9:00 - JST 1945 Sep 15
8:00 HK HK%sT
-
###############################################################################
# Taiwan
@@ -2236,9 +2307,23 @@ Rule Syria 2007 only - Nov Fri>=1 0:00
# http://www.timeanddate.com/news/time/syria-dst-starts-march-27-2009.html
#
+# From Steffen Thorsen (2009-10-27):
+# The Syrian Arab News Network on 2009-09-29 reported that Syria will
+# revert back to winter (standard) time on midnight between Thursday
+# 2009-10-29 and Friday 2009-10-30:
+#
+# http://www.sana.sy/ara/2/2009/09/29/247012.htm (Arabic)
+#
+
+# From Arthur David Olson (2009-10-28):
+# We'll see if future DST switching times turn out to be end of the last
+# Thursday of the month or the start of the last Friday of the month or
+# something else. For now, use the start of the last Friday.
+
Rule Syria 2008 only - Apr Fri>=1 0:00 1:00 S
-Rule Syria 2008 max - Nov 1 0:00 0 -
+Rule Syria 2008 only - Nov 1 0:00 0 -
Rule Syria 2009 max - Mar lastFri 0:00 1:00 S
+Rule Syria 2009 max - Oct lastFri 0:00 0 -
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Damascus 2:25:12 - LMT 1920 # Dimashq
Modified: head/share/zoneinfo/europe
==============================================================================
--- head/share/zoneinfo/europe Mon Nov 2 21:40:50 2009 (r198824)
+++ head/share/zoneinfo/europe Mon Nov 2 21:44:10 2009 (r198825)
@@ -1,5 +1,5 @@
#
-# @(#)europe 8.22
+# @(#)europe 8.24
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
@@ -2072,9 +2072,43 @@ Zone Asia/Novosibirsk 5:31:40 - LMT 191
6:00 Russia NOV%sT 1992 Jan 19 2:00s
7:00 Russia NOV%sT 1993 May 23 # say Shanks & P.
6:00 Russia NOV%sT
+
+# From Alexander Krivenyshev (2009-10-13):
+# Kemerovo oblast' (Kemerovo region) in Russia will change current time zone on
+# March 28, 2010:
+# from current Russia Zone 6 - Krasnoyarsk Time Zone (KRA) UTC +0700
+# to Russia Zone 5 - Novosibirsk Time Zone (NOV) UTC +0600
+#
+# This is according to Government of Russia decree # 740, on September
+# 14, 2009 "Application in the territory of the Kemerovo region the Fifth
+# time zone." ("Russia Zone 5" or old "USSR Zone 5" is GMT +0600)
+#
+# Russian Government web site (Russian language)
+#
+# http://www.government.ru/content/governmentactivity/rfgovernmentdecisions/archive/2009/09/14/991633.htm
+#
+# or Russian-English translation by WorldTimeZone.com with reference
+# map to local region and new Russia Time Zone map after March 28, 2010
+#
+# http://www.worldtimezone.com/dst_news/dst_news_russia03.html
+#
+#
+# Thus, when Russia will switch to DST on the night of March 28, 2010
+# Kemerovo region (Kemerovo oblast') will not change the clock.
+#
+# As a result, Kemerovo oblast' will be in the same time zone as
+# Novosibirsk, Omsk, Tomsk, Barnaul and Altai Republic.
+
+Zone Asia/Novokuznetsk 5:48:48 - NMT 1920 Jan 6
+ 6:00 - KRAT 1930 Jun 21 # Krasnoyarsk Time
+ 7:00 Russia KRA%sT 1991 Mar 31 2:00s
+ 6:00 Russia KRA%sT 1992 Jan 19 2:00s
+ 7:00 Russia KRA%sT 2010 Mar 28 2:00s
+ 6:00 Russia NOV%sT # Novosibirsk/Novokuznetsk Time
+
#
# From Oscar van Vlijmen (2001-08-25): [This region consists of]
-# Kemerovskaya oblast', Krasnoyarskij kraj,
+# Krasnoyarskij kraj,
# Tajmyrskij (Dolgano-Nenetskij) avtonomnyj okrug,
# Respublika Tuva, Respublika Khakasiya, Evenkijskij avtonomnyj okrug.
Zone Asia/Krasnoyarsk 6:11:20 - LMT 1920 Jan 6
Modified: head/share/zoneinfo/zone.tab
==============================================================================
--- head/share/zoneinfo/zone.tab Mon Nov 2 21:40:50 2009 (r198824)
+++ head/share/zoneinfo/zone.tab Mon Nov 2 21:44:10 2009 (r198825)
@@ -1,5 +1,5 @@
#
-# @(#)zone.tab 8.28
+# @(#)zone.tab 8.29
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
#
@@ -330,6 +330,7 @@ RU +5312+05009 Europe/Samara Moscow+01 -
RU +5651+06036 Asia/Yekaterinburg Moscow+02 - Urals
RU +5500+07324 Asia/Omsk Moscow+03 - west Siberia
RU +5502+08255 Asia/Novosibirsk Moscow+03 - Novosibirsk
+RU +5345+08707 Asia/Novokuznetsk Moscow+03 - Novokuznetsk
RU +5601+09250 Asia/Krasnoyarsk Moscow+04 - Yenisei River
RU +5216+10420 Asia/Irkutsk Moscow+05 - Lake Baikal
RU +6200+12940 Asia/Yakutsk Moscow+06 - Lena River
From simon at FreeBSD.org Mon Nov 2 21:44:58 2009
From: simon at FreeBSD.org (Simon L. Nielsen)
Date: Mon Nov 2 21:45:04 2009
Subject: svn commit: r198826 - svnadmin/hooks/scripts
Message-ID: <200911022144.nA2Liw4K070791@svn.freebsd.org>
Author: simon
Date: Mon Nov 2 21:44:57 2009
New Revision: 198826
URL: http://svn.freebsd.org/changeset/base/198826
Log:
Only print the 'Directory Properties' section if we actually have
changed directory properties.
Modified:
svnadmin/hooks/scripts/mailer.py
Modified: svnadmin/hooks/scripts/mailer.py
==============================================================================
--- svnadmin/hooks/scripts/mailer.py Mon Nov 2 21:44:10 2009 (r198825)
+++ svnadmin/hooks/scripts/mailer.py Mon Nov 2 21:44:57 2009 (r198826)
@@ -1062,7 +1062,8 @@ class TextCommitRenderer:
text = ' unchanged'
w(' - copied%s from r%d, %s%s\n'
% (text, d.base_rev, d.base_path, is_dir))
- w('Directory Properties:\n%s' % (ps))
+ if len(ps) > 0:
+ w('Directory Properties:\n%s' % (ps))
def _render_diffs(self, diffs, section_header):
"""Render diffs. Write the SECTION_HEADER if there are actually
From edwin at FreeBSD.org Mon Nov 2 22:32:15 2009
From: edwin at FreeBSD.org (Edwin Groothuis)
Date: Mon Nov 2 22:32:21 2009
Subject: svn commit: r198828 - in vendor/tzcode/dist: unused zic
Message-ID: <200911022232.nA2MWEsm071854@svn.freebsd.org>
Author: edwin
Date: Mon Nov 2 22:32:14 2009
New Revision: 198828
URL: http://svn.freebsd.org/changeset/base/198828
Log:
Vendor import of tzcode2009q:
- Add more references in tz-art.htm
- Cleanup unnecessary local variables in zdump.
Obtained from: ftp://elsie.nci.nih.gov/pub/
Modified:
vendor/tzcode/dist/unused/tz-art.htm
vendor/tzcode/dist/zic/zdump.c
Modified: vendor/tzcode/dist/unused/tz-art.htm
==============================================================================
--- vendor/tzcode/dist/unused/tz-art.htm Mon Nov 2 21:48:00 2009 (r198827)
+++ vendor/tzcode/dist/unused/tz-art.htm Mon Nov 2 22:32:14 2009 (r198828)
@@ -9,7 +9,7 @@ PUBLIC "-//W3C//DTD HTML 4.01//EN"
Time and the Arts
-@(#)tz-art.htm 8.13
+@(#)tz-art.htm 8.14
This file is in the public domain, so clarified as of
@@ -354,7 +354,8 @@ premonition in the "We Had a Dream" epis
(originally aired 2007-02-28).
-In the 1946 "A Matter of Life and Death,"
+In the 1946 movie "A Matter of Life and Death"
+(U.S. title "Stairway to Heaven")
there is a reference to British Double Summer Time.
The time does not play a large part in the plot;
it's just a passing reference to the time when one of the
@@ -363,6 +364,31 @@ The IMDb page is at
http://us.imdb.com/title/tt0038733/
. (Dave Cantor)
+
+The 1953 railway comedy movie "The Titfield Thunderbolt" includes a
+play on words on British Double Summer Time. Valentine's wife wants
+him to leave the pub and asks him, "Do you know what time it is?"
+And he, happy where he is, replies: "Yes, my love. Summer double time."
+IMDB page:
+
+http://us.imdb.com/title/tt0046436/
+. (Mark Brader, 2009-10-02)
+
+
+The premise of the 1999 caper movie "Entrapment" involves computers
+in an international banking network being shut down briefly at
+midnight in each time zone to avoid any problems at the transition
+from the year 1999 to 2000 in that zone. (Hmmmm.) If this shutdown
+is extended by 10 seconds, it will create a one-time opportunity for
+a gigantic computerized theft. To achieve this, at one location the
+crooks interfere with the microwave system supplying time signals to
+the computer, advancing the time by 0.1 second each minute over the
+last hour of 1999. (So this movie teaches us that 0.1 x 60 = 10.)
+IMDB page:
+
+http://us.imdb.com/title/tt0137494/
+. (Mark Brader, 2009-10-02)
+
Modified: vendor/tzcode/dist/zic/zdump.c
==============================================================================
--- vendor/tzcode/dist/zic/zdump.c Mon Nov 2 21:48:00 2009 (r198827)
+++ vendor/tzcode/dist/zic/zdump.c Mon Nov 2 22:32:14 2009 (r198828)
@@ -3,7 +3,7 @@
** 2009-05-17 by Arthur David Olson.
*/
-static char elsieid[] = "@(#)zdump.c 8.9";
+static char elsieid[] = "@(#)zdump.c 8.10";
/*
** This code has been made independent of the rest of the time
@@ -236,7 +236,9 @@ const char * const zone;
}
static void
-usage(const char *progname, FILE *stream, int status)
+usage(stream, status)
+FILE * const stream;
+const int status
{
(void) fprintf(stream,
_("%s: usage is %s [ --version ] [ --help ] [ -v ] [ -c [loyear,]hiyear ] zonename ...\n\
@@ -283,7 +285,7 @@ char * argv[];
(void) printf("%s\n", elsieid);
exit(EXIT_SUCCESS);
} else if (strcmp(argv[i], "--help") == 0) {
- usage(progname, stdout, EXIT_SUCCESS);
+ usage(stdout, EXIT_SUCCESS);
}
vflag = 0;
cutarg = NULL;
@@ -293,7 +295,7 @@ char * argv[];
else cutarg = optarg;
if ((c != EOF && c != -1) ||
(optind == argc - 1 && strcmp(argv[optind], "=") == 0)) {
- usage(progname, stderr, EXIT_FAILURE);
+ usage(stderr, EXIT_FAILURE);
}
if (vflag) {
if (cutarg != NULL) {
From edwin at FreeBSD.org Mon Nov 2 22:33:04 2009
From: edwin at FreeBSD.org (Edwin Groothuis)
Date: Mon Nov 2 22:33:11 2009
Subject: svn commit: r198829 - vendor/tzcode/tzcode2009q
Message-ID: <200911022233.nA2MX4A1071930@svn.freebsd.org>
Author: edwin
Date: Mon Nov 2 22:33:04 2009
New Revision: 198829
URL: http://svn.freebsd.org/changeset/base/198829
Log:
Tag of tzcode2009q
Added:
vendor/tzcode/tzcode2009q/
- copied from r198828, vendor/tzcode/dist/
From edwin at FreeBSD.org Mon Nov 2 23:02:12 2009
From: edwin at FreeBSD.org (Edwin Groothuis)
Date: Mon Nov 2 23:02:27 2009
Subject: svn commit: r198831 - head/usr.sbin/zic
Message-ID: <200911022302.nA2N2BBA072716@svn.freebsd.org>
Author: edwin
Date: Mon Nov 2 23:02:11 2009
New Revision: 198831
URL: http://svn.freebsd.org/changeset/base/198831
Log:
MFV of r198828, tzcode2009q
- Cleanup unnecessary local variables in zdump.
- Fix man-page
MFC after: 1 week
Modified:
head/usr.sbin/zic/zdump.c
head/usr.sbin/zic/zic.8
Directory Properties:
head/usr.sbin/zic/ (props changed)
Modified: head/usr.sbin/zic/zdump.c
==============================================================================
--- head/usr.sbin/zic/zdump.c Mon Nov 2 22:50:39 2009 (r198830)
+++ head/usr.sbin/zic/zdump.c Mon Nov 2 23:02:11 2009 (r198831)
@@ -6,7 +6,7 @@
#ifndef lint
static const char rcsid[] =
"$FreeBSD$";
-static char elsieid[] = "@(#)zdump.c 8.9";
+static char elsieid[] = "@(#)zdump.c 8.10";
#endif /* not lint */
/*
@@ -152,7 +152,7 @@ static size_t longest;
static char * progname;
static int warned;
-static void usage(const char *progname, FILE *stream, int status);
+static void usage(FILE *stream, int status);
static char * abbr(struct tm * tmp);
static void abbrok(const char * abbrp, const char * zone);
static long delta(struct tm * newp, struct tm * oldp);
@@ -273,7 +273,7 @@ char * argv[];
if (strcmp(argv[i], "--version") == 0) {
errx(EXIT_SUCCESS, "%s", elsieid);
} else if (strcmp(argv[i], "--help") == 0) {
- usage(progname, stdout, EXIT_SUCCESS);
+ usage(stdout, EXIT_SUCCESS);
}
vflag = 0;
cutarg = NULL;
@@ -283,7 +283,7 @@ char * argv[];
else cutarg = optarg;
if ((c != -1) ||
(optind == argc - 1 && strcmp(argv[optind], "=") == 0)) {
- usage(progname, stderr, EXIT_FAILURE);
+ usage(stderr, EXIT_FAILURE);
}
if (vflag) {
if (cutarg != NULL) {
@@ -468,7 +468,7 @@ const long y;
}
static void
-usage(const char *progname, FILE *stream, int status)
+usage(FILE *stream, int status)
{
fprintf(stream,
_("usage: %s [--version] [-v] [--help] [-c [loyear,]hiyear] zonename ...\n\
Modified: head/usr.sbin/zic/zic.8
==============================================================================
--- head/usr.sbin/zic/zic.8 Mon Nov 2 22:50:39 2009 (r198830)
+++ head/usr.sbin/zic/zic.8 Mon Nov 2 23:02:11 2009 (r198831)
@@ -260,7 +260,7 @@ the variable part is null.
.El
.Pp
A zone line has the form:
-.Dl "Zone NAME GMTOFF RULES/SAVE FORMAT [UNTILYEAR [MONTH [DAY [TIME]]]]
+.Dl "Zone NAME GMTOFF RULES/SAVE FORMAT [UNTILYEAR [MONTH [DAY [TIME]]]]"
For example:
.Dl "Zone Australia/Adelaide 9:30 Aus CST 1971 Oct 31 2:00
The fields that make up a zone line are:
From thompsa at FreeBSD.org Mon Nov 2 23:30:16 2009
From: thompsa at FreeBSD.org (Andrew Thompson)
Date: Mon Nov 2 23:30:27 2009
Subject: svn commit: r198832 - head/sys/cam/scsi
Message-ID: <200911022330.nA2NUF3b073300@svn.freebsd.org>
Author: thompsa
Date: Mon Nov 2 23:30:15 2009
New Revision: 198832
URL: http://svn.freebsd.org/changeset/base/198832
Log:
Provide the same sanity check on the sector size in dagetcapacity as when the
disk is first probed. dagetcapacity is called whenever the disk is opened from
geom via d_open(), a zero sector size will cause geom to panic later on.
Modified:
head/sys/cam/scsi/scsi_da.c
Modified: head/sys/cam/scsi/scsi_da.c
==============================================================================
--- head/sys/cam/scsi/scsi_da.c Mon Nov 2 23:02:11 2009 (r198831)
+++ head/sys/cam/scsi/scsi_da.c Mon Nov 2 23:30:15 2009 (r198832)
@@ -1948,8 +1948,15 @@ dagetcapacity(struct cam_periph *periph)
done:
- if (error == 0)
- dasetgeom(periph, block_len, maxsector);
+ if (error == 0) {
+ if (block_len >= MAXPHYS || block_len == 0) {
+ xpt_print(periph->path,
+ "unsupportable block size %ju\n",
+ (uintmax_t) block_len);
+ error = EINVAL;
+ } else
+ dasetgeom(periph, block_len, maxsector);
+ }
xpt_release_ccb(ccb);
From thompsa at FreeBSD.org Mon Nov 2 23:50:13 2009
From: thompsa at FreeBSD.org (Andrew Thompson)
Date: Mon Nov 2 23:50:24 2009
Subject: svn commit: r198833 - head/usr.sbin/usbconfig
Message-ID: <200911022350.nA2NoCcr073693@svn.freebsd.org>
Author: thompsa
Date: Mon Nov 2 23:50:12 2009
New Revision: 198833
URL: http://svn.freebsd.org/changeset/base/198833
Log:
Add more verbose output when dumping the configuration descriptor.
Submitted by: Hans Petter Selasky
Modified:
head/usr.sbin/usbconfig/dump.c
Modified: head/usr.sbin/usbconfig/dump.c
==============================================================================
--- head/usr.sbin/usbconfig/dump.c Mon Nov 2 23:30:15 2009 (r198832)
+++ head/usr.sbin/usbconfig/dump.c Mon Nov 2 23:50:12 2009 (r198833)
@@ -100,21 +100,66 @@ dump_field(struct libusb20_device *pdev,
printf("%s%s = 0x%04x ", plevel, field, value);
- if ((field[0] != 'i') || (field[1] == 'd')) {
- printf("\n");
- return;
- }
- if (value == 0) {
- printf(" \n");
- return;
+ if (strlen(plevel) == 8) {
+ /* Endpoint Descriptor */
+
+ if (strcmp(field, "bEndpointAddress") == 0) {
+ if (value & 0x80)
+ printf(" \n");
+ else
+ printf(" \n");
+ return;
+ }
+
+ if (strcmp(field, "bmAttributes") == 0) {
+ switch (value & 0x03) {
+ case 0:
+ printf(" \n");
+ break;
+ case 1:
+ switch (value & 0x0C) {
+ case 0x00:
+ printf(" \n");
+ break;
+ case 0x04:
+ printf(" \n");
+ break;
+ case 0x08:
+ printf(" \n");
+ break;
+ default:
+ printf(" \n");
+ break;
+ }
+ break;
+ case 2:
+ printf(" \n");
+ break;
+ default:
+ printf(" \n");
+ break;
+ }
+ return;
+ }
}
- if (libusb20_dev_req_string_simple_sync(pdev, value,
- temp_string, sizeof(temp_string))) {
- printf(" \n");
+
+ if ((field[0] == 'i') && (field[1] != 'd')) {
+ /* Indirect String Descriptor */
+ if (value == 0) {
+ printf(" \n");
+ return;
+ }
+ if (libusb20_dev_req_string_simple_sync(pdev, value,
+ temp_string, sizeof(temp_string))) {
+ printf(" \n");
+ return;
+ }
+ printf(" <%s>\n", temp_string);
return;
}
- printf(" <%s>\n", temp_string);
- return;
+
+ /* No additional information */
+ printf("\n");
}
static void
From oleg at FreeBSD.org Tue Nov 3 08:41:15 2009
From: oleg at FreeBSD.org (Oleg Bulyzhin)
Date: Tue Nov 3 08:41:29 2009
Subject: svn commit: r198845 - head/sys/netinet/ipfw
Message-ID: <200911030841.nA38fEg3084563@svn.freebsd.org>
Author: oleg
Date: Tue Nov 3 08:41:14 2009
New Revision: 198845
URL: http://svn.freebsd.org/changeset/base/198845
Log:
Fix two issues that can lead to exceeding configured pipe bandwidth:
- do not expire queues which are not ready to be expired.
- properly calculate available burst size.
MFC after: 3 days
Modified:
head/sys/netinet/ipfw/ip_dummynet.c
Modified: head/sys/netinet/ipfw/ip_dummynet.c
==============================================================================
--- head/sys/netinet/ipfw/ip_dummynet.c Tue Nov 3 07:29:58 2009 (r198844)
+++ head/sys/netinet/ipfw/ip_dummynet.c Tue Nov 3 08:41:14 2009 (r198845)
@@ -244,6 +244,17 @@ void dummynet_drain(void);
static int dummynet_io(struct mbuf **, int , struct ip_fw_args *);
/*
+ * Flow queue is idle if:
+ * 1) it's empty for at least 1 tick
+ * 2) it has invalid timestamp (WF2Q case)
+ * 3) parent pipe has no 'exhausted' burst.
+ */
+#define QUEUE_IS_IDLE(q) ((q)->head == NULL && (q)->S == (q)->F + 1 && \
+ curr_time > (q)->idle_time + 1 && \
+ ((q)->numbytes + (curr_time - (q)->idle_time - 1) * \
+ (q)->fs->pipe->bandwidth >= q->fs->pipe->burst))
+
+/*
* Heap management functions.
*
* In the heap, first node is element 0. Children of i are 2i+1 and 2i+2.
@@ -1004,7 +1015,7 @@ expire_queues(struct dn_flow_set *fs)
fs->last_expired = time_uptime ;
for (i = 0 ; i <= fs->rq_size ; i++) /* last one is overflow */
for (prev=NULL, q = fs->rq[i] ; q != NULL ; )
- if (q->head != NULL || q->S != q->F+1) {
+ if (!QUEUE_IS_IDLE(q)) {
prev = q ;
q = q->next ;
} else { /* entry is idle, expire it */
@@ -1134,7 +1145,7 @@ find_queue(struct dn_flow_set *fs, struc
break ; /* found */
/* No match. Check if we can expire the entry */
- if (pipe_expire && q->head == NULL && q->S == q->F+1 ) {
+ if (pipe_expire && QUEUE_IS_IDLE(q)) {
/* entry is idle and not in any heap, expire it */
struct dn_flow_queue *old_q = q ;
@@ -1408,7 +1419,7 @@ dummynet_io(struct mbuf **m0, int dir, s
if (q->idle_time < curr_time) {
/* Calculate available burst size. */
q->numbytes +=
- (curr_time - q->idle_time) * pipe->bandwidth;
+ (curr_time - q->idle_time - 1) * pipe->bandwidth;
if (q->numbytes > pipe->burst)
q->numbytes = pipe->burst;
if (io_fast)
@@ -1418,8 +1429,8 @@ dummynet_io(struct mbuf **m0, int dir, s
if (pipe->idle_time < curr_time) {
/* Calculate available burst size. */
pipe->numbytes +=
- (curr_time - pipe->idle_time) * pipe->bandwidth;
- if (pipe->numbytes > pipe->burst)
+ (curr_time - pipe->idle_time - 1) * pipe->bandwidth;
+ if (pipe->numbytes > 0 && pipe->numbytes > pipe->burst)
pipe->numbytes = pipe->burst;
if (io_fast)
pipe->numbytes += pipe->bandwidth;
From oleg at FreeBSD.org Tue Nov 3 09:04:04 2009
From: oleg at FreeBSD.org (Oleg Bulyzhin)
Date: Tue Nov 3 09:04:15 2009
Subject: svn commit: r198845 - head/sys/netinet/ipfw
In-Reply-To: <200911030841.nA38fEg3084563@svn.freebsd.org>
References: <200911030841.nA38fEg3084563@svn.freebsd.org>
Message-ID: <20091103084518.GA45306@lath.rinet.ru>
On Tue, Nov 03, 2009 at 08:41:14AM +0000, Oleg Bulyzhin wrote:
> Author: oleg
> Date: Tue Nov 3 08:41:14 2009
> New Revision: 198845
> URL: http://svn.freebsd.org/changeset/base/198845
>
> Log:
> Fix two issues that can lead to exceeding configured pipe bandwidth:
> - do not expire queues which are not ready to be expired.
> - properly calculate available burst size.
>
> MFC after: 3 days
>
> Modified:
> head/sys/netinet/ipfw/ip_dummynet.c
Reviews are welcome, since i'm going to push this into 8.0-RELEASE.
Thanks.
--
Oleg.
================================================================
=== Oleg Bulyzhin -- OBUL-RIPN -- OBUL-RIPE -- oleg@rinet.ru ===
================================================================
From delphij at FreeBSD.org Tue Nov 3 09:17:24 2009
From: delphij at FreeBSD.org (Xin LI)
Date: Tue Nov 3 09:17:30 2009
Subject: svn commit: r198846 - head/usr.sbin/crashinfo
Message-ID: <200911030917.nA39HNCF085239@svn.freebsd.org>
Author: delphij
Date: Tue Nov 3 09:17:23 2009
New Revision: 198846
URL: http://svn.freebsd.org/changeset/base/198846
Log:
Set umask to 0x077 instead of the default. This prevents non-root user
from reading crashinfo output, which could contain some sensitive
information.
Reviewed by: jhb
MFC after: 1 week
Modified:
head/usr.sbin/crashinfo/crashinfo.sh
Modified: head/usr.sbin/crashinfo/crashinfo.sh
==============================================================================
--- head/usr.sbin/crashinfo/crashinfo.sh Tue Nov 3 08:41:14 2009 (r198845)
+++ head/usr.sbin/crashinfo/crashinfo.sh Tue Nov 3 09:17:23 2009 (r198846)
@@ -147,6 +147,8 @@ fi
echo "Writing crash summary to $FILE."
+umask 077
+
# Simulate uname
ostype=$(echo -e printf '"%s", ostype' | gdb -x /dev/stdin -batch $KERNEL)
osrelease=$(echo -e printf '"%s", osrelease' | gdb -x /dev/stdin -batch $KERNEL)
From delphij at FreeBSD.org Tue Nov 3 09:25:08 2009
From: delphij at FreeBSD.org (Xin LI)
Date: Tue Nov 3 09:25:15 2009
Subject: svn commit: r198847 - head/usr.bin/leave
Message-ID: <200911030925.nA39P8EM085486@svn.freebsd.org>
Author: delphij
Date: Tue Nov 3 09:25:08 2009
New Revision: 198847
URL: http://svn.freebsd.org/changeset/base/198847
Log:
Static'ify signal handler which is not called from outside.
Modified:
head/usr.bin/leave/leave.c
Modified: head/usr.bin/leave/leave.c
==============================================================================
--- head/usr.bin/leave/leave.c Tue Nov 3 09:17:23 2009 (r198846)
+++ head/usr.bin/leave/leave.c Tue Nov 3 09:25:08 2009 (r198847)
@@ -53,7 +53,7 @@ __FBSDID("$FreeBSD$");
#include
#include
-void doalarm(u_int);
+static void doalarm(u_int);
static void usage(void);
/*
From delphij at FreeBSD.org Tue Nov 3 09:28:46 2009
From: delphij at FreeBSD.org (Xin LI)
Date: Tue Nov 3 09:28:57 2009
Subject: svn commit: r198848 - head/bin/ps
Message-ID: <200911030928.nA39SjLx085597@svn.freebsd.org>
Author: delphij
Date: Tue Nov 3 09:28:45 2009
New Revision: 198848
URL: http://svn.freebsd.org/changeset/base/198848
Log:
Increase width for %CPU, RSS and VSZ columns for now. Modern systems
tend to have larger memory, larger process, and more CPU.
Modified:
head/bin/ps/keyword.c
Modified: head/bin/ps/keyword.c
==============================================================================
--- head/bin/ps/keyword.c Tue Nov 3 09:25:08 2009 (r198847)
+++ head/bin/ps/keyword.c Tue Nov 3 09:28:45 2009 (r198848)
@@ -70,7 +70,7 @@ static int vcmp(const void *, const voi
/* PLEASE KEEP THE TABLE BELOW SORTED ALPHABETICALLY!!! */
static VAR var[] = {
- {"%cpu", "%CPU", NULL, 0, pcpu, NULL, 4, 0, CHAR, NULL, 0},
+ {"%cpu", "%CPU", NULL, 0, pcpu, NULL, 5, 0, CHAR, NULL, 0},
{"%mem", "%MEM", NULL, 0, pmem, NULL, 4, 0, CHAR, NULL, 0},
{"acflag", "ACFLG", NULL, 0, kvar, NULL, 3, KOFF(ki_acflag), USHORT,
"x", 0},
@@ -159,7 +159,7 @@ static VAR var[] = {
UINT, UIDFMT, 0},
{"rgroup", "RGROUP", NULL, LJUST|DSIZ, rgroupname, s_rgroupname,
USERLEN, 0, CHAR, NULL, 0},
- {"rss", "RSS", NULL, 0, kvar, NULL, 5, KOFF(ki_rssize), PGTOK, "ld", 0},
+ {"rss", "RSS", NULL, 0, kvar, NULL, 6, KOFF(ki_rssize), PGTOK, "ld", 0},
{"rtprio", "RTPRIO", NULL, 0, priorityr, NULL, 7, KOFF(ki_pri), CHAR,
NULL, 0},
{"ruid", "RUID", NULL, 0, kvar, NULL, UIDLEN, KOFF(ki_ruid),
@@ -207,7 +207,7 @@ static VAR var[] = {
NULL, 0},
{"usrpri", "", "upr", 0, NULL, NULL, 0, 0, CHAR, NULL, 0},
{"vsize", "", "vsz", 0, NULL, NULL, 0, 0, CHAR, NULL, 0},
- {"vsz", "VSZ", NULL, 0, vsize, NULL, 5, 0, CHAR, NULL, 0},
+ {"vsz", "VSZ", NULL, 0, vsize, NULL, 6, 0, CHAR, NULL, 0},
{"wchan", "WCHAN", NULL, LJUST, wchan, NULL, 6, 0, CHAR, NULL, 0},
{"xstat", "XSTAT", NULL, 0, kvar, NULL, 4, KOFF(ki_xstat), USHORT,
"x", 0},
From max at love2party.net Tue Nov 3 10:15:28 2009
From: max at love2party.net (Max Laier)
Date: Tue Nov 3 10:15:35 2009
Subject: svn commit: r198826 - svnadmin/hooks/scripts
In-Reply-To: <200911022144.nA2Liw4K070791@svn.freebsd.org>
References: <200911022144.nA2Liw4K070791@svn.freebsd.org>
Message-ID: <200911031113.59437.max@love2party.net>
On Monday 02 November 2009 22:44:58 Simon L. Nielsen wrote:
> Author: simon
> Date: Mon Nov 2 21:44:57 2009
> New Revision: 198826
> URL: http://svn.freebsd.org/changeset/base/198826
>
> Log:
> Only print the 'Directory Properties' section if we actually have
> changed directory properties.
Thank you for the commit and sorry for this oversight. This is mine.
> Modified:
> svnadmin/hooks/scripts/mailer.py
>
> Modified: svnadmin/hooks/scripts/mailer.py
> ===========================================================================
> === --- svnadmin/hooks/scripts/mailer.py Mon Nov 2 21:44:10 2009 (r198825)
> +++ svnadmin/hooks/scripts/mailer.py Mon Nov 2 21:44:57 2009 (r198826) @@
> -1062,7 +1062,8 @@ class TextCommitRenderer:
> text = ' unchanged'
> w(' - copied%s from r%d, %s%s\n'
> % (text, d.base_rev, d.base_path, is_dir))
> - w('Directory Properties:\n%s' % (ps))
> + if len(ps) > 0:
> + w('Directory Properties:\n%s' % (ps))
>
> def _render_diffs(self, diffs, section_header):
> """Render diffs. Write the SECTION_HEADER if there are actually
>
>
> !DSPAM:4aef52ed799761205380022!
>
--
/"\ Best regards, | mlaier@freebsd.org
\ / Max Laier | ICQ #67774661
X http://pf4freebsd.love2party.net/ | mlaier@EFnet
/ \ ASCII Ribbon Campaign | Against HTML Mail and News
From mav at FreeBSD.org Tue Nov 3 11:19:06 2009
From: mav at FreeBSD.org (Alexander Motin)
Date: Tue Nov 3 11:19:18 2009
Subject: svn commit: r198849 - in head/sys/cam: . ata
Message-ID: <200911031119.nA3BJ50K090039@svn.freebsd.org>
Author: mav
Date: Tue Nov 3 11:19:05 2009
New Revision: 198849
URL: http://svn.freebsd.org/changeset/base/198849
Log:
MFp4:
Improve reporting ATA Status error details.
Modified:
head/sys/cam/ata/ata_all.c
head/sys/cam/ata/ata_all.h
head/sys/cam/cam.c
head/sys/cam/cam.h
head/sys/cam/cam_periph.c
Modified: head/sys/cam/ata/ata_all.c
==============================================================================
--- head/sys/cam/ata/ata_all.c Tue Nov 3 09:28:45 2009 (r198848)
+++ head/sys/cam/ata/ata_all.c Tue Nov 3 11:19:05 2009 (r198849)
@@ -68,6 +68,185 @@ ata_version(int ver)
return 0;
}
+char *
+ata_op_string(struct ata_cmd *cmd)
+{
+
+ switch (cmd->command) {
+ case 0x00: return ("NOP");
+ case 0x03: return ("CFA_REQUEST_EXTENDED_ERROR");
+ case 0x08: return ("DEVICE_RESET");
+ case 0x20: return ("READ");
+ case 0x24: return ("READ48");
+ case 0x25: return ("READ_DMA48");
+ case 0x26: return ("READ_DMA_QUEUED48");
+ case 0x27: return ("READ_NATIVE_MAX_ADDRESS48");
+ case 0x29: return ("READ_MUL48");
+ case 0x2a: return ("READ_STREAM_DMA48");
+ case 0x2b: return ("READ_STREAM48");
+ case 0x2f: return ("READ_LOG_EXT");
+ case 0x30: return ("WRITE");
+ case 0x34: return ("WRITE48");
+ case 0x35: return ("WRITE_DMA48");
+ case 0x36: return ("WRITE_DMA_QUEUED48");
+ case 0x37: return ("SET_MAX_ADDRESS48");
+ case 0x39: return ("WRITE_MUL48");
+ case 0x3a: return ("WRITE_STREAM_DMA48");
+ case 0x3b: return ("WRITE_STREAM48");
+ case 0x3d: return ("WRITE_DMA_FUA");
+ case 0x3e: return ("WRITE_DMA_FUA48");
+ case 0x3f: return ("WRITE_LOG_EXT");
+ case 0x40: return ("READ_VERIFY");
+ case 0x42: return ("READ_VERIFY48");
+ case 0x51: return ("CONFIGURE_STREAM");
+ case 0x60: return ("READ_FPDMA_QUEUED");
+ case 0x61: return ("WRITE_FPDMA_QUEUED");
+ case 0x70: return ("SEEK");
+ case 0x87: return ("CFA_TRANSLATE_SECTOR");
+ case 0x90: return ("EXECUTE_DEVICE_DIAGNOSTIC");
+ case 0x92: return ("DOWNLOAD_MICROCODE");
+ case 0xa0: return ("PACKET");
+ case 0xa1: return ("ATAPI_IDENTIFY");
+ case 0xa2: return ("SERVICE");
+ case 0xb0: return ("SMART");
+ case 0xb1: return ("DEVICE CONFIGURATION");
+ case 0xc0: return ("CFA_ERASE");
+ case 0xc4: return ("READ_MUL");
+ case 0xc5: return ("WRITE_MUL");
+ case 0xc6: return ("SET_MULTI");
+ case 0xc7: return ("READ_DMA_QUEUED");
+ case 0xc8: return ("READ_DMA");
+ case 0xca: return ("WRITE_DMA");
+ case 0xcc: return ("WRITE_DMA_QUEUED");
+ case 0xcd: return ("CFA_WRITE_MULTIPLE_WITHOUT_ERASE");
+ case 0xce: return ("WRITE_MULTIPLE_FUA48");
+ case 0xd1: return ("CHECK_MEDIA_CARD_TYPE");
+ case 0xda: return ("GET_MEDIA_STATUS");
+ case 0xde: return ("MEDIA_LOCK");
+ case 0xdf: return ("MEDIA_UNLOCK");
+ case 0xe0: return ("STANDBY_IMMEDIATE");
+ case 0xe1: return ("IDLE_IMMEDIATE");
+ case 0xe2: return ("STANDBY");
+ case 0xe3: return ("IDLE");
+ case 0xe4: return ("READ_BUFFER/PM");
+ case 0xe5: return ("CHECK_POWER_MODE");
+ case 0xe6: return ("SLEEP");
+ case 0xe7: return ("FLUSHCACHE");
+ case 0xe8: return ("WRITE_PM");
+ case 0xea: return ("FLUSHCACHE48");
+ case 0xec: return ("ATA_IDENTIFY");
+ case 0xed: return ("MEDIA_EJECT");
+ case 0xef:
+ switch (cmd->features) {
+ case 0x03: return ("SETFEATURES SET TRANSFER MODE");
+ case 0x02: return ("SETFEATURES ENABLE WCACHE");
+ case 0x82: return ("SETFEATURES DISABLE WCACHE");
+ case 0xaa: return ("SETFEATURES ENABLE RCACHE");
+ case 0x55: return ("SETFEATURES DISABLE RCACHE");
+ }
+ return "SETFEATURES";
+ case 0xf1: return ("SECURITY_SET_PASSWORD");
+ case 0xf2: return ("SECURITY_UNLOCK");
+ case 0xf3: return ("SECURITY_ERASE_PREPARE");
+ case 0xf4: return ("SECURITY_ERASE_UNIT");
+ case 0xf5: return ("SECURITY_FREE_LOCK");
+ case 0xf6: return ("SECURITY DISABLE PASSWORD");
+ case 0xf8: return ("READ_NATIVE_MAX_ADDRESS");
+ case 0xf9: return ("SET_MAX_ADDRESS");
+ }
+ return "UNKNOWN";
+}
+
+char *
+ata_cmd_string(struct ata_cmd *cmd, char *cmd_string, size_t len)
+{
+
+ snprintf(cmd_string, len, "%02x %02x %02x %02x "
+ "%02x %02x %02x %02x %02x %02x %02x %02x",
+ cmd->command, cmd->features,
+ cmd->lba_low, cmd->lba_mid, cmd->lba_high, cmd->device,
+ cmd->lba_low_exp, cmd->lba_mid_exp, cmd->lba_high_exp,
+ cmd->features_exp, cmd->sector_count, cmd->sector_count_exp);
+
+ return(cmd_string);
+}
+
+char *
+ata_res_string(struct ata_res *res, char *res_string, size_t len)
+{
+
+ snprintf(res_string, len, "%02x %02x %02x %02x "
+ "%02x %02x %02x %02x %02x %02x %02x",
+ res->status, res->error,
+ res->lba_low, res->lba_mid, res->lba_high, res->device,
+ res->lba_low_exp, res->lba_mid_exp, res->lba_high_exp,
+ res->sector_count, res->sector_count_exp);
+
+ return(res_string);
+}
+
+/*
+ * ata_command_sbuf() returns 0 for success and -1 for failure.
+ */
+int
+ata_command_sbuf(struct ccb_ataio *ataio, struct sbuf *sb)
+{
+ char cmd_str[(12 * 3) + 1];
+
+ sbuf_printf(sb, "CMD: %s: %s",
+ ata_op_string(&ataio->cmd),
+ ata_cmd_string(&ataio->cmd, cmd_str, sizeof(cmd_str)));
+
+ return(0);
+}
+
+/*
+ * ata_status_abuf() returns 0 for success and -1 for failure.
+ */
+int
+ata_status_sbuf(struct ccb_ataio *ataio, struct sbuf *sb)
+{
+
+ sbuf_printf(sb, "ATA Status: %02x (%s%s%s%s%s%s%s%s)",
+ ataio->res.status,
+ (ataio->res.status & 0x80) ? "BSY " : "",
+ (ataio->res.status & 0x40) ? "DRDY " : "",
+ (ataio->res.status & 0x20) ? "DF " : "",
+ (ataio->res.status & 0x10) ? "SERV " : "",
+ (ataio->res.status & 0x08) ? "DRQ " : "",
+ (ataio->res.status & 0x04) ? "CORR " : "",
+ (ataio->res.status & 0x02) ? "IDX " : "",
+ (ataio->res.status & 0x01) ? "ERR" : "");
+ if (ataio->res.status & 1) {
+ sbuf_printf(sb, ", Error: %02x (%s%s%s%s%s%s%s%s)",
+ ataio->res.error,
+ (ataio->res.error & 0x80) ? "ICRC " : "",
+ (ataio->res.error & 0x40) ? "UNC " : "",
+ (ataio->res.error & 0x20) ? "MC " : "",
+ (ataio->res.error & 0x10) ? "IDNF " : "",
+ (ataio->res.error & 0x08) ? "MCR " : "",
+ (ataio->res.error & 0x04) ? "ABRT " : "",
+ (ataio->res.error & 0x02) ? "NM " : "",
+ (ataio->res.error & 0x01) ? "ILI" : "");
+ }
+
+ return(0);
+}
+
+/*
+ * ata_res_sbuf() returns 0 for success and -1 for failure.
+ */
+int
+ata_res_sbuf(struct ccb_ataio *ataio, struct sbuf *sb)
+{
+ char res_str[(11 * 3) + 1];
+
+ sbuf_printf(sb, "RES: %s",
+ ata_res_string(&ataio->res, res_str, sizeof(res_str)));
+
+ return(0);
+}
+
void
ata_print_ident(struct ata_params *ident_data)
{
Modified: head/sys/cam/ata/ata_all.h
==============================================================================
--- head/sys/cam/ata/ata_all.h Tue Nov 3 09:28:45 2009 (r198848)
+++ head/sys/cam/ata/ata_all.h Tue Nov 3 11:19:05 2009 (r198849)
@@ -81,6 +81,14 @@ struct ata_res {
};
int ata_version(int ver);
+
+char * ata_op_string(struct ata_cmd *cmd);
+char * ata_cmd_string(struct ata_cmd *cmd, char *cmd_string, size_t len);
+char * ata_res_string(struct ata_res *res, char *res_string, size_t len);
+int ata_command_sbuf(struct ccb_ataio *ataio, struct sbuf *sb);
+int ata_status_sbuf(struct ccb_ataio *ataio, struct sbuf *sb);
+int ata_res_sbuf(struct ccb_ataio *ataio, struct sbuf *sb);
+
void ata_print_ident(struct ata_params *ident_data);
void ata_28bit_cmd(struct ccb_ataio *ataio, uint8_t cmd, uint8_t features,
Modified: head/sys/cam/cam.c
==============================================================================
--- head/sys/cam/cam.c Tue Nov 3 09:28:45 2009 (r198848)
+++ head/sys/cam/cam.c Tue Nov 3 11:19:05 2009 (r198849)
@@ -229,6 +229,21 @@ cam_error_string(struct cam_device *devi
return(NULL);
switch (ccb->ccb_h.func_code) {
+ case XPT_ATA_IO:
+ switch (proto_flags & CAM_EPF_LEVEL_MASK) {
+ case CAM_EPF_NONE:
+ break;
+ case CAM_EPF_ALL:
+ case CAM_EPF_NORMAL:
+ proto_flags |= CAM_EAF_PRINT_RESULT;
+ /* FALLTHROUGH */
+ case CAM_EPF_MINIMAL:
+ proto_flags |= CAM_EAF_PRINT_STATUS;
+ /* FALLTHROUGH */
+ default:
+ break;
+ }
+ break;
case XPT_SCSI_IO:
switch (proto_flags & CAM_EPF_LEVEL_MASK) {
case CAM_EPF_NONE:
@@ -256,10 +271,12 @@ cam_error_string(struct cam_device *devi
sbuf_new(&sb, str, str_len, 0);
if (flags & CAM_ESF_COMMAND) {
-
sbuf_cat(&sb, path_str);
-
switch (ccb->ccb_h.func_code) {
+ case XPT_ATA_IO:
+ ata_command_sbuf(&ccb->ataio, &sb);
+ sbuf_printf(&sb, "\n");
+ break;
case XPT_SCSI_IO:
#ifdef _KERNEL
scsi_command_string(&ccb->csio, &sb);
@@ -267,7 +284,6 @@ cam_error_string(struct cam_device *devi
scsi_command_string(device, &ccb->csio, &sb);
#endif /* _KERNEL/!_KERNEL */
sbuf_printf(&sb, "\n");
-
break;
default:
break;
@@ -295,6 +311,22 @@ cam_error_string(struct cam_device *devi
if (flags & CAM_ESF_PROTO_STATUS) {
switch (ccb->ccb_h.func_code) {
+ case XPT_ATA_IO:
+ if ((ccb->ccb_h.status & CAM_STATUS_MASK) !=
+ CAM_ATA_STATUS_ERROR)
+ break;
+ if (proto_flags & CAM_EAF_PRINT_STATUS) {
+ sbuf_cat(&sb, path_str);
+ ata_status_sbuf(&ccb->ataio, &sb);
+ sbuf_printf(&sb, "\n");
+ }
+ if (proto_flags & CAM_EAF_PRINT_RESULT) {
+ sbuf_cat(&sb, path_str);
+ ata_res_sbuf(&ccb->ataio, &sb);
+ sbuf_printf(&sb, "\n");
+ }
+
+ break;
case XPT_SCSI_IO:
if ((ccb->ccb_h.status & CAM_STATUS_MASK) !=
CAM_SCSI_STATUS_ERROR)
@@ -302,10 +334,6 @@ cam_error_string(struct cam_device *devi
if (proto_flags & CAM_ESF_PRINT_STATUS) {
sbuf_cat(&sb, path_str);
- /*
- * Print out the SCSI status byte as long as
- * the user wants some protocol output.
- */
sbuf_printf(&sb, "SCSI Status: %s\n",
scsi_status_string(&ccb->csio));
}
Modified: head/sys/cam/cam.h
==============================================================================
--- head/sys/cam/cam.h Tue Nov 3 09:28:45 2009 (r198848)
+++ head/sys/cam/cam.h Tue Nov 3 11:19:05 2009 (r198849)
@@ -184,6 +184,12 @@ typedef enum {
CAM_ESF_PRINT_SENSE = 0x20
} cam_error_scsi_flags;
+typedef enum {
+ CAM_EAF_PRINT_NONE = 0x00,
+ CAM_EAF_PRINT_STATUS = 0x10,
+ CAM_EAF_PRINT_RESULT = 0x20
+} cam_error_ata_flags;
+
struct cam_status_entry
{
cam_status status_code;
Modified: head/sys/cam/cam_periph.c
==============================================================================
--- head/sys/cam/cam_periph.c Tue Nov 3 09:28:45 2009 (r198848)
+++ head/sys/cam/cam_periph.c Tue Nov 3 11:19:05 2009 (r198849)
@@ -1612,6 +1612,7 @@ cam_periph_error(union ccb *ccb, cam_fla
if (bootverbose && printed == 0) {
xpt_print(ccb->ccb_h.path,
"Request completed with CAM_ATA_STATUS_ERROR\n");
+ cam_error_print(ccb, CAM_ESF_ALL, CAM_EPF_ALL);
printed++;
}
/* FALLTHROUGH */
From brde at optusnet.com.au Tue Nov 3 11:31:55 2009
From: brde at optusnet.com.au (Bruce Evans)
Date: Tue Nov 3 11:32:06 2009
Subject: svn commit: r198848 - head/bin/ps
In-Reply-To: <200911030928.nA39SjLx085597@svn.freebsd.org>
References: <200911030928.nA39SjLx085597@svn.freebsd.org>
Message-ID: <20091103214231.H23957@delplex.bde.org>
On Tue, 3 Nov 2009, Xin LI wrote:
> Log:
> Increase width for %CPU, RSS and VSZ columns for now. Modern systems
> tend to have larger memory, larger process, and more CPU.
This uses space that is not available. Command names(+args) are now
truncated to 9 columns in "ps l" output :-(. They used to be truncated to
11 columns recently (down from 12 columns in FreeBSD-5.2).
%CPU != CPU. Modern systems don't really have more %CPU. The maximum
percentage of anything is still 100.0. However, there are various bugs
that result in a percentage of 100.0 being misdisplayed and "percentages"
of more than 100.0 occurring:
- ps used %4.1f format. This works for all percentages <= 99.9 (after
rounding), but not for 100.0. Now ps uses %5.1 format, so 100.0 is
displayed correctly, but all normal percentages are displayed worse
than before (space that is not available is used to make them harder
to read).
- %CPU is not divided by the number of CPUs. Thus a multi-threaded
process can have %CPU almost as large as * 100.0.
This might be a feature. E.g., on mostly-idle systems, the idle
process consists of threads which take akmost
100.0% CPU each, so the total %CPU for the idle process is almost
the above maximum (it is now 799.2 on ref8.freebsd.org due to ref8
having 8 mostly-idle CPUs). Since ps now uses %5.1 format, it can
display %CPU correctly on all systems with <= 9 CPUs, and on most
systems with 10 CPUs (since the value of 1000.0 which is too wide
for %5.1 format is even harder to reach on a 10-CPU system than
the value of 100.0 which is too wide for %4.1 format is to reach on
1 a-CPU system). The format is still broken on systems with >= 11 CPUs.
- perhaps schedular bugs can result in %CPU being transiently slightly
greater than 100.0 for an individual thread.
Expanding %CPU doesn't truncate "ps l" since "ps l" doesn't print %CPU.
Thus the recent truncation is only from 11 COMMAND columns to 9 instead
of to 8.
There seems to be no better fix than to further granulate and dehumanize
the numbers so that they fit in the available space. E.g., a %CPU of
>= 100 and < 9999 should be displayed in %4.0f format; this only
involvues granulation, but above 9999 it needs to be dehumanized as
well and displayed in k or M or larger granularity (it can be > 9999
with 100 CPUs and > 999k with 10000 CPUs). A VSZ of >= 10000 (k
implicit) needs to be displayed in M or larger granularity (M explicit).
Bruce
From ed at FreeBSD.org Tue Nov 3 11:41:21 2009
From: ed at FreeBSD.org (Ed Schouten)
Date: Tue Nov 3 11:41:33 2009
Subject: svn commit: r198850 - head/sbin/sysctl
Message-ID: <200911031141.nA3BfLNB090451@svn.freebsd.org>
Author: ed
Date: Tue Nov 3 11:41:21 2009
New Revision: 198850
URL: http://svn.freebsd.org/changeset/base/198850
Log:
Just use devname(3) to print device names.
Right now sysctl just prints the major/minor numbers of a device.
Instead of rolling our own routine for this, we'd better just call
devname(3) to perform a translation to a device name for us.
Modified:
head/sbin/sysctl/sysctl.c
Modified: head/sbin/sysctl/sysctl.c
==============================================================================
--- head/sbin/sysctl/sysctl.c Tue Nov 3 11:19:05 2009 (r198849)
+++ head/sbin/sysctl/sysctl.c Tue Nov 3 11:41:21 2009 (r198850)
@@ -419,14 +419,7 @@ T_dev_t(int l2, void *p)
warnx("T_dev_T %d != %d", l2, sizeof(*d));
return (1);
}
- if ((int)(*d) != -1) {
- if (minor(*d) > 255 || minor(*d) < 0)
- printf("{ major = %d, minor = 0x%x }",
- major(*d), minor(*d));
- else
- printf("{ major = %d, minor = %d }",
- major(*d), minor(*d));
- }
+ printf("%s", devname(*d, S_IFCHR));
return (0);
}
From mav at FreeBSD.org Tue Nov 3 11:47:07 2009
From: mav at FreeBSD.org (Alexander Motin)
Date: Tue Nov 3 11:47:22 2009
Subject: svn commit: r198851 - head/sys/dev/ahci
Message-ID: <200911031147.nA3Bl7PF090601@svn.freebsd.org>
Author: mav
Date: Tue Nov 3 11:47:07 2009
New Revision: 198851
URL: http://svn.freebsd.org/changeset/base/198851
Log:
MFp4:
- Handle timeouts and fatal errors with port hard-reset. The rest of
recovery will be done by XPT on receiving async event. More gracefull
per-device soft-reset recovery can be implemented later.
- Add workaround for ATI SB600/SB700 PMP probe related bug, to speedup boot.
Modified:
head/sys/dev/ahci/ahci.c
head/sys/dev/ahci/ahci.h
Modified: head/sys/dev/ahci/ahci.c
==============================================================================
--- head/sys/dev/ahci/ahci.c Tue Nov 3 11:41:21 2009 (r198850)
+++ head/sys/dev/ahci/ahci.c Tue Nov 3 11:47:07 2009 (r198851)
@@ -1221,6 +1221,13 @@ ahci_execute_transaction(struct ahci_slo
et = AHCI_ERR_TFE;
break;
}
+ /* Workaround for ATI SB600/SB700 chipsets. */
+ if (ccb->ccb_h.target_id == 15 &&
+ pci_get_vendor(device_get_parent(dev)) == 0x1002 &&
+ (ATA_INL(ch->r_mem, AHCI_P_IS) & AHCI_P_IX_IPM)) {
+ et = AHCI_ERR_TIMEOUT;
+ break;
+ }
}
if (timeout && (count >= timeout)) {
device_printf(ch->dev,
@@ -1275,10 +1282,8 @@ ahci_timeout(struct ahci_slot *slot)
ATA_INL(ch->r_mem, AHCI_P_IS), ATA_INL(ch->r_mem, AHCI_P_CI),
ATA_INL(ch->r_mem, AHCI_P_SACT), ch->rslots,
ATA_INL(ch->r_mem, AHCI_P_TFD), ATA_INL(ch->r_mem, AHCI_P_SERR));
- /* Kick controller into sane state. */
- ahci_stop(ch->dev);
- ahci_start(ch->dev);
+ ch->fatalerr = 1;
/* Handle frozen command. */
if (ch->frozen) {
union ccb *fccb = ch->frozen;
@@ -1360,6 +1365,7 @@ ahci_end_transaction(struct ahci_slot *s
ccb->csio.scsi_status = SCSI_STATUS_OK;
break;
case AHCI_ERR_INVALID:
+ ch->fatalerr = 1;
ccb->ccb_h.status |= CAM_REQ_INVALID;
break;
case AHCI_ERR_INNOCENT:
@@ -1375,6 +1381,7 @@ ahci_end_transaction(struct ahci_slot *s
}
break;
case AHCI_ERR_SATA:
+ ch->fatalerr = 1;
if (!ch->readlog) {
xpt_freeze_simq(ch->sim, 1);
ccb->ccb_h.status &= ~CAM_STATUS_MASK;
@@ -1383,6 +1390,10 @@ ahci_end_transaction(struct ahci_slot *s
ccb->ccb_h.status |= CAM_UNCOR_PARITY;
break;
case AHCI_ERR_TIMEOUT:
+ /* Do no treat soft-reset timeout as fatal here. */
+ if (ccb->ccb_h.func_code != XPT_ATA_IO ||
+ !(ccb->ataio.cmd.flags & CAM_ATAIO_CONTROL))
+ ch->fatalerr = 1;
if (!ch->readlog) {
xpt_freeze_simq(ch->sim, 1);
ccb->ccb_h.status &= ~CAM_STATUS_MASK;
@@ -1391,6 +1402,7 @@ ahci_end_transaction(struct ahci_slot *s
ccb->ccb_h.status |= CAM_CMD_TIMEOUT;
break;
default:
+ ch->fatalerr = 1;
ccb->ccb_h.status |= CAM_REQ_CMP_ERR;
}
/* Free slot. */
@@ -1414,12 +1426,13 @@ ahci_end_transaction(struct ahci_slot *s
ahci_begin_transaction(dev, ccb);
return;
}
+ /* If it was our READ LOG command - process it. */
+ if (ch->readlog) {
+ ahci_process_read_log(dev, ccb);
/* If it was NCQ command error, put result on hold. */
- if (et == AHCI_ERR_NCQ) {
+ } else if (et == AHCI_ERR_NCQ) {
ch->hold[slot->slot] = ccb;
- } else if (ch->readlog) /* If it was our READ LOG command - process it. */
- ahci_process_read_log(dev, ccb);
- else
+ } else
xpt_done(ccb);
/* Unfreeze frozen command. */
if (ch->frozen && ch->numrslots == 0) {
@@ -1428,6 +1441,13 @@ ahci_end_transaction(struct ahci_slot *s
ahci_begin_transaction(dev, fccb);
xpt_release_simq(ch->sim, TRUE);
}
+ /* If we have no other active commands, ... */
+ if (ch->rslots == 0) {
+ /* if there was fatal error - reset port. */
+ if (ch->fatalerr) {
+ ahci_reset(dev);
+ }
+ }
/* Start PM timer. */
if (ch->numrslots == 0 && ch->pm_level > 3) {
callout_schedule(&ch->pm_timer,
@@ -1674,6 +1694,13 @@ ahci_reset(device_t dev)
/* XXX; Commands in loading state. */
ahci_end_transaction(&ch->slot[i], AHCI_ERR_INNOCENT);
}
+ for (i = 0; i < ch->numslots; i++) {
+ if (!ch->hold[i])
+ continue;
+ xpt_done(ch->hold[i]);
+ ch->hold[i] = NULL;
+ }
+ ch->fatalerr = 0;
/* Tell the XPT about the event */
xpt_async(AC_BUS_RESET, ch->path, NULL);
/* Disable port interrupts */
Modified: head/sys/dev/ahci/ahci.h
==============================================================================
--- head/sys/dev/ahci/ahci.h Tue Nov 3 11:41:21 2009 (r198850)
+++ head/sys/dev/ahci/ahci.h Tue Nov 3 11:47:07 2009 (r198851)
@@ -366,6 +366,7 @@ struct ahci_channel {
int numrslots; /* Number of running slots */
int numtslots; /* Number of tagged slots */
int readlog; /* Our READ LOG active */
+ int fatalerr; /* Fatal error happend */
int lastslot; /* Last used slot */
int taggedtarget; /* Last tagged target */
union ccb *frozen; /* Frozen command */
From mav at FreeBSD.org Tue Nov 3 12:03:13 2009
From: mav at FreeBSD.org (Alexander Motin)
Date: Tue Nov 3 12:03:25 2009
Subject: svn commit: r198852 - head/sys/dev/siis
Message-ID: <200911031203.nA3C3DGn090939@svn.freebsd.org>
Author: mav
Date: Tue Nov 3 12:03:13 2009
New Revision: 198852
URL: http://svn.freebsd.org/changeset/base/198852
Log:
MFp4:
- Rework timeout handling, to make it more graceful for devices sharing
controller port (with PMP). Wait for other commands completion/timeout
before initiating recovery.
- Handle timeouts and fatal errors with port hard-reset. The rest of
recovery will be done by XPT on receiving async event. More gracefull
per-device soft-reset recovery can be implemented later.
Modified:
head/sys/dev/siis/siis.c
head/sys/dev/siis/siis.h
Modified: head/sys/dev/siis/siis.c
==============================================================================
--- head/sys/dev/siis/siis.c Tue Nov 3 11:47:07 2009 (r198851)
+++ head/sys/dev/siis/siis.c Tue Nov 3 12:03:13 2009 (r198852)
@@ -511,7 +511,10 @@ siis_ch_resume(device_t dev)
/* Get port out of reset state. */
ATA_OUTL(ch->r_mem, SIIS_P_CTLCLR, SIIS_P_CTL_PORT_RESET);
ATA_OUTL(ch->r_mem, SIIS_P_CTLCLR, SIIS_P_CTL_32BIT);
- ATA_OUTL(ch->r_mem, SIIS_P_CTLCLR, SIIS_P_CTL_PME);
+ if (ch->pm_present)
+ ATA_OUTL(ch->r_mem, SIIS_P_CTLSET, SIIS_P_CTL_PME);
+ else
+ ATA_OUTL(ch->r_mem, SIIS_P_CTLCLR, SIIS_P_CTL_PME);
/* Enable port interrupts */
ATA_OUTL(ch->r_mem, SIIS_P_IESET, SIIS_P_IX_ENABLED);
return (0);
@@ -764,7 +767,7 @@ siis_ch_intr(void *data)
estatus == SIIS_P_CMDERR_DATAFIS) {
tslots = ch->numtslots[port];
for (i = 0; i < SIIS_MAX_SLOTS; i++) {
- /* XXX: reqests in loading state. */
+ /* XXX: requests in loading state. */
if (((ch->rslots >> i) & 1) == 0)
continue;
if (ch->slot[i].ccb->ccb_h.target_id != port)
@@ -796,7 +799,7 @@ siis_ch_intr(void *data)
} else
et = SIIS_ERR_INVALID;
for (i = 0; i < SIIS_MAX_SLOTS; i++) {
- /* XXX: reqests in loading state. */
+ /* XXX: requests in loading state. */
if (((ch->rslots >> i) & 1) == 0)
continue;
siis_end_transaction(&ch->slot[i], et);
@@ -967,48 +970,51 @@ siis_execute_transaction(struct siis_slo
return;
}
-/* Locked by callout mechanism. */
+/* Must be called with channel locked. */
static void
-siis_timeout(struct siis_slot *slot)
+siis_process_timeout(device_t dev)
{
- device_t dev = slot->dev;
struct siis_channel *ch = device_get_softc(dev);
int i;
mtx_assert(&ch->mtx, MA_OWNED);
- device_printf(dev, "Timeout on slot %d\n", slot->slot);
-device_printf(dev, "%s is %08x ss %08x rs %08x es %08x sts %08x serr %08x\n",
- __func__, ATA_INL(ch->r_mem, SIIS_P_IS), ATA_INL(ch->r_mem, SIIS_P_SS), ch->rslots,
- ATA_INL(ch->r_mem, SIIS_P_CMDERR), ATA_INL(ch->r_mem, SIIS_P_STS),
- ATA_INL(ch->r_mem, SIIS_P_SERR));
- /* Kick controller into sane state. */
- siis_portinit(ch->dev);
-
- if (!ch->readlog)
+ if (!ch->readlog && !ch->recovery) {
xpt_freeze_simq(ch->sim, ch->numrslots);
- /* Handle frozen command. */
- if (ch->frozen) {
- union ccb *fccb = ch->frozen;
- ch->frozen = NULL;
- fccb->ccb_h.status &= ~CAM_STATUS_MASK;
- fccb->ccb_h.status |= CAM_REQUEUE_REQ | CAM_RELEASE_SIMQ;
- if (!(fccb->ccb_h.status & CAM_DEV_QFRZN)) {
- xpt_freeze_devq(fccb->ccb_h.path, 1);
- fccb->ccb_h.status |= CAM_DEV_QFRZN;
- }
- xpt_done(fccb);
+ ch->recovery = 1;
}
- /* Handle command with timeout. */
- siis_end_transaction(&ch->slot[slot->slot], SIIS_ERR_TIMEOUT);
/* Handle the rest of commands. */
for (i = 0; i < SIIS_MAX_SLOTS; i++) {
/* Do we have a running request on slot? */
if (ch->slot[i].state < SIIS_SLOT_RUNNING)
continue;
- siis_end_transaction(&ch->slot[i], SIIS_ERR_INNOCENT);
+ siis_end_transaction(&ch->slot[i], SIIS_ERR_TIMEOUT);
}
}
+/* Locked by callout mechanism. */
+static void
+siis_timeout(struct siis_slot *slot)
+{
+ device_t dev = slot->dev;
+ struct siis_channel *ch = device_get_softc(dev);
+
+ mtx_assert(&ch->mtx, MA_OWNED);
+ device_printf(dev, "Timeout on slot %d\n", slot->slot);
+device_printf(dev, "%s is %08x ss %08x rs %08x es %08x sts %08x serr %08x\n",
+ __func__, ATA_INL(ch->r_mem, SIIS_P_IS), ATA_INL(ch->r_mem, SIIS_P_SS), ch->rslots,
+ ATA_INL(ch->r_mem, SIIS_P_CMDERR), ATA_INL(ch->r_mem, SIIS_P_STS),
+ ATA_INL(ch->r_mem, SIIS_P_SERR));
+
+ if (ch->toslots == 0)
+ xpt_freeze_simq(ch->sim, 1);
+ ch->toslots |= (1 << slot->slot);
+ if ((ch->rslots & ~ch->toslots) == 0)
+ siis_process_timeout(dev);
+ else
+ device_printf(dev, " ... waiting for slots %08x\n",
+ ch->rslots & ~ch->toslots);
+}
+
/* Must be called with channel locked. */
static void
siis_end_transaction(struct siis_slot *slot, enum siis_err_type et)
@@ -1071,6 +1077,7 @@ siis_end_transaction(struct siis_slot *s
ccb->csio.scsi_status = SCSI_STATUS_OK;
break;
case SIIS_ERR_INVALID:
+ ch->fatalerr = 1;
ccb->ccb_h.status |= CAM_REQ_INVALID;
break;
case SIIS_ERR_INNOCENT:
@@ -1086,9 +1093,11 @@ siis_end_transaction(struct siis_slot *s
}
break;
case SIIS_ERR_SATA:
+ ch->fatalerr = 1;
ccb->ccb_h.status |= CAM_UNCOR_PARITY;
break;
case SIIS_ERR_TIMEOUT:
+ ch->fatalerr = 1;
ccb->ccb_h.status |= CAM_CMD_TIMEOUT;
break;
default:
@@ -1097,6 +1106,11 @@ siis_end_transaction(struct siis_slot *s
/* Free slot. */
ch->rslots &= ~(1 << slot->slot);
ch->aslots &= ~(1 << slot->slot);
+ if (et != SIIS_ERR_TIMEOUT) {
+ if (ch->toslots == (1 << slot->slot))
+ xpt_release_simq(ch->sim, TRUE);
+ ch->toslots &= ~(1 << slot->slot);
+ }
slot->state = SIIS_SLOT_EMPTY;
slot->ccb = NULL;
/* Update channel stats. */
@@ -1105,13 +1119,14 @@ siis_end_transaction(struct siis_slot *s
(ccb->ataio.cmd.flags & CAM_ATAIO_FPDMA)) {
ch->numtslots[ccb->ccb_h.target_id]--;
}
+ /* If it was our READ LOG command - process it. */
+ if (ch->readlog) {
+ siis_process_read_log(dev, ccb);
/* If it was NCQ command error, put result on hold. */
- if (et == SIIS_ERR_NCQ) {
+ } else if (et == SIIS_ERR_NCQ) {
ch->hold[slot->slot] = ccb;
ch->numhslots++;
- } else if (ch->readlog) /* If it was our READ LOG command - process it. */
- siis_process_read_log(dev, ccb);
- else
+ } else
xpt_done(ccb);
/* Unfreeze frozen command. */
if (ch->frozen && ch->numrslots == 0) {
@@ -1122,13 +1137,20 @@ siis_end_transaction(struct siis_slot *s
}
/* If we have no other active commands, ... */
if (ch->rslots == 0) {
- /* if we have slots in error, we can reinit port. */
- if (ch->eslots != 0)
- siis_portinit(dev);
- /* if there commands on hold, we can do READ LOG. */
- if (!ch->readlog && ch->numhslots)
- siis_issue_read_log(dev);
- }
+ /* if there were timeouts or fatal error - reset port. */
+ if (ch->toslots != 0 || ch->fatalerr) {
+ siis_reset(dev);
+ } else {
+ /* if we have slots in error, we can reinit port. */
+ if (ch->eslots != 0)
+ siis_portinit(dev);
+ /* if there commands on hold, we can do READ LOG. */
+ if (!ch->readlog && ch->numhslots)
+ siis_issue_read_log(dev);
+ }
+ /* If all the reset of commands are in timeout - abort them. */
+ } else if ((ch->rslots & ~ch->toslots) == 0)
+ siis_process_timeout(dev);
}
static void
@@ -1296,13 +1318,14 @@ static void
siis_reset(device_t dev)
{
struct siis_channel *ch = device_get_softc(dev);
- int i;
+ int i, retry = 0;
uint32_t val;
if (bootverbose)
device_printf(dev, "SIIS reset...\n");
- xpt_freeze_simq(ch->sim, ch->numrslots);
- /* Requeue freezed command. */
+ if (!ch->readlog && !ch->recovery)
+ xpt_freeze_simq(ch->sim, ch->numrslots);
+ /* Requeue frozen command. */
if (ch->frozen) {
union ccb *fccb = ch->frozen;
ch->frozen = NULL;
@@ -1322,6 +1345,20 @@ siis_reset(device_t dev)
/* XXX; Commands in loading state. */
siis_end_transaction(&ch->slot[i], SIIS_ERR_INNOCENT);
}
+ /* Finish all holden commands as-is. */
+ for (i = 0; i < SIIS_MAX_SLOTS; i++) {
+ if (!ch->hold[i])
+ continue;
+ xpt_done(ch->hold[i]);
+ ch->hold[i] = NULL;
+ ch->numhslots--;
+ }
+ if (ch->toslots != 0)
+ xpt_release_simq(ch->sim, TRUE);
+ ch->eslots = 0;
+ ch->recovery = 0;
+ ch->toslots = 0;
+ ch->fatalerr = 0;
/* Disable port interrupts */
ATA_OUTL(ch->r_mem, SIIS_P_IECLR, 0x0000FFFF);
/* Set speed limit. */
@@ -1336,6 +1373,7 @@ siis_reset(device_t dev)
ATA_OUTL(ch->r_mem, SIIS_P_SCTL,
ATA_SC_DET_IDLE | val | ((ch->pm_level > 0) ? 0 :
(ATA_SC_IPM_DIS_PARTIAL | ATA_SC_IPM_DIS_SLUMBER)));
+retry:
siis_devreset(dev);
/* Reset and reconnect PHY, */
if (!siis_sata_connect(ch)) {
@@ -1350,8 +1388,25 @@ siis_reset(device_t dev)
return;
}
/* Wait for clearing busy status. */
- if (siis_wait_ready(dev, 10000))
+ if (siis_wait_ready(dev, 10000)) {
device_printf(dev, "device ready timeout\n");
+ if (!retry) {
+ device_printf(dev, "trying full port reset ...\n");
+ /* Get port to the reset state. */
+ ATA_OUTL(ch->r_mem, SIIS_P_CTLSET, SIIS_P_CTL_PORT_RESET);
+ DELAY(10000);
+ /* Get port out of reset state. */
+ ATA_OUTL(ch->r_mem, SIIS_P_CTLCLR, SIIS_P_CTL_PORT_RESET);
+ ATA_OUTL(ch->r_mem, SIIS_P_CTLCLR, SIIS_P_CTL_32BIT);
+ if (ch->pm_present)
+ ATA_OUTL(ch->r_mem, SIIS_P_CTLSET, SIIS_P_CTL_PME);
+ else
+ ATA_OUTL(ch->r_mem, SIIS_P_CTLCLR, SIIS_P_CTL_PME);
+ siis_wait_ready(dev, 5000);
+ retry = 1;
+ goto retry;
+ }
+ }
ch->devices = 1;
/* Enable port interrupts */
ATA_OUTL(ch->r_mem, SIIS_P_IS, 0xFFFFFFFF);
@@ -1487,7 +1542,8 @@ siisaction(struct cam_sim *sim, union cc
struct ccb_trans_settings *cts = &ccb->cts;
if (cts->xport_specific.sata.valid & CTS_SATA_VALID_PM) {
- if (cts->xport_specific.sata.pm_present)
+ ch->pm_present = cts->xport_specific.sata.pm_present;
+ if (ch->pm_present)
ATA_OUTL(ch->r_mem, SIIS_P_CTLSET, SIIS_P_CTL_PME);
else
ATA_OUTL(ch->r_mem, SIIS_P_CTLCLR, SIIS_P_CTL_PME);
@@ -1522,9 +1578,7 @@ siisaction(struct cam_sim *sim, union cc
cts->xport_specific.sata.bitrate = 150000;
cts->xport_specific.sata.valid |= CTS_SATA_VALID_SPEED;
}
- cts->xport_specific.sata.pm_present =
- (ATA_INL(ch->r_mem, SIIS_P_STS) & SIIS_P_CTL_PME) ?
- 1 : 0;
+ cts->xport_specific.sata.pm_present = ch->pm_present;
cts->xport_specific.sata.valid |= CTS_SATA_VALID_PM;
ccb->ccb_h.status = CAM_REQ_CMP;
xpt_done(ccb);
Modified: head/sys/dev/siis/siis.h
==============================================================================
--- head/sys/dev/siis/siis.h Tue Nov 3 11:47:07 2009 (r198851)
+++ head/sys/dev/siis/siis.h Tue Nov 3 12:03:13 2009 (r198852)
@@ -373,13 +373,14 @@ struct siis_channel {
uint32_t rslots; /* Running slots */
uint32_t aslots; /* Slots with atomic commands */
uint32_t eslots; /* Slots in error */
+ uint32_t toslots; /* Slots in timeout */
int numrslots; /* Number of running slots */
int numtslots[SIIS_MAX_SLOTS]; /* Number of tagged slots */
int numhslots; /* Number of holden slots */
int readlog; /* Our READ LOG active */
+ int fatalerr; /* Fatal error happend */
int recovery; /* Some slots are in error */
int lastslot; /* Last used slot */
- int taggedtarget; /* Last tagged target */
union ccb *frozen; /* Frozen command */
};
From kib at FreeBSD.org Tue Nov 3 12:52:35 2009
From: kib at FreeBSD.org (Konstantin Belousov)
Date: Tue Nov 3 12:52:47 2009
Subject: svn commit: r198853 - head/sys/kern
Message-ID: <200911031252.nA3CqZdj092015@svn.freebsd.org>
Author: kib
Date: Tue Nov 3 12:52:35 2009
New Revision: 198853
URL: http://svn.freebsd.org/changeset/base/198853
Log:
If socket buffer space appears to be lower then sum of count of already
prepared bytes and next portion of transfer, inner loop of kern_sendfile()
aborts, not preparing next mbuf for socket buffer, and not modifying
any outer loop invariants. The thread loops in the outer loop forever.
Instead of breaking from inner loop, prepare only bytes that fit into
the socket buffer space.
In collaboration with: pho
Reviewed by: bz
PR: kern/138999
MFC after: 2 weeks
Modified:
head/sys/kern/uipc_syscalls.c
Modified: head/sys/kern/uipc_syscalls.c
==============================================================================
--- head/sys/kern/uipc_syscalls.c Tue Nov 3 12:03:13 2009 (r198852)
+++ head/sys/kern/uipc_syscalls.c Tue Nov 3 12:52:35 2009 (r198853)
@@ -2037,20 +2037,12 @@ retry_space:
rem = obj->un_pager.vnp.vnp_size -
uap->offset - fsbytes - loopbytes;
xfsize = omin(rem, xfsize);
+ xfsize = omin(space - loopbytes, xfsize);
if (xfsize <= 0) {
VM_OBJECT_UNLOCK(obj);
done = 1; /* all data sent */
break;
}
- /*
- * Don't overflow the send buffer.
- * Stop here and send out what we've
- * already got.
- */
- if (space < loopbytes + xfsize) {
- VM_OBJECT_UNLOCK(obj);
- break;
- }
/*
* Attempt to look up the page. Allocate
From attilio at FreeBSD.org Tue Nov 3 16:46:52 2009
From: attilio at FreeBSD.org (Attilio Rao)
Date: Tue Nov 3 16:47:13 2009
Subject: svn commit: r198854 - in head/sys: kern sys vm
Message-ID: <200911031646.nA3GkqB4096838@svn.freebsd.org>
Author: attilio
Date: Tue Nov 3 16:46:52 2009
New Revision: 198854
URL: http://svn.freebsd.org/changeset/base/198854
Log:
Split P_NOLOAD into a per-thread flag (TDF_NOLOAD).
This improvements aims for avoiding further cache-misses in scheduler
specific functions which need to keep track of average thread running
time and further locking in places setting for this flag.
Reported by: jeff (originally), kris (currently)
Reviewed by: jhb
Tested by: Giuseppe Cocomazzi
Modified:
head/sys/kern/kern_idle.c
head/sys/kern/kern_intr.c
head/sys/kern/sched_4bsd.c
head/sys/kern/sched_ule.c
head/sys/sys/proc.h
head/sys/vm/vm_zeroidle.c
Modified: head/sys/kern/kern_idle.c
==============================================================================
--- head/sys/kern/kern_idle.c Tue Nov 3 12:52:35 2009 (r198853)
+++ head/sys/kern/kern_idle.c Tue Nov 3 16:46:52 2009 (r198854)
@@ -74,10 +74,9 @@ idle_setup(void *dummy)
if (error)
panic("idle_setup: kproc_create error %d\n", error);
- p->p_flag |= P_NOLOAD;
thread_lock(td);
TD_SET_CAN_RUN(td);
- td->td_flags |= TDF_IDLETD;
+ td->td_flags |= TDF_IDLETD | TDF_NOLOAD;
sched_class(td, PRI_IDLE);
sched_prio(td, PRI_MAX_IDLE);
thread_unlock(td);
Modified: head/sys/kern/kern_intr.c
==============================================================================
--- head/sys/kern/kern_intr.c Tue Nov 3 12:52:35 2009 (r198853)
+++ head/sys/kern/kern_intr.c Tue Nov 3 16:46:52 2009 (r198854)
@@ -1061,6 +1061,7 @@ int
swi_add(struct intr_event **eventp, const char *name, driver_intr_t handler,
void *arg, int pri, enum intr_type flags, void **cookiep)
{
+ struct thread *td;
struct intr_event *ie;
int error;
@@ -1085,11 +1086,10 @@ swi_add(struct intr_event **eventp, cons
if (error)
return (error);
if (pri == SWI_CLOCK) {
- struct proc *p;
- p = ie->ie_thread->it_thread->td_proc;
- PROC_LOCK(p);
- p->p_flag |= P_NOLOAD;
- PROC_UNLOCK(p);
+ td = ie->ie_thread->it_thread;
+ thread_lock(td);
+ td->td_flags |= TDF_NOLOAD;
+ thread_unlock(td);
}
return (0);
}
Modified: head/sys/kern/sched_4bsd.c
==============================================================================
--- head/sys/kern/sched_4bsd.c Tue Nov 3 12:52:35 2009 (r198853)
+++ head/sys/kern/sched_4bsd.c Tue Nov 3 16:46:52 2009 (r198854)
@@ -728,10 +728,10 @@ sched_exit_thread(struct thread *td, str
thread_lock(td);
td->td_estcpu = ESTCPULIM(td->td_estcpu + child->td_estcpu);
thread_unlock(td);
- mtx_lock_spin(&sched_lock);
- if ((child->td_proc->p_flag & P_NOLOAD) == 0)
+ thread_lock(child);
+ if ((child->td_flags & TDF_NOLOAD) == 0)
sched_load_rem();
- mtx_unlock_spin(&sched_lock);
+ thread_unlock(child);
}
void
@@ -937,7 +937,7 @@ sched_switch(struct thread *td, struct t
thread_unlock(td);
}
- if ((p->p_flag & P_NOLOAD) == 0)
+ if ((td->td_flags & TDF_NOLOAD) == 0)
sched_load_rem();
if (newtd)
@@ -980,7 +980,7 @@ sched_switch(struct thread *td, struct t
("trying to run inhibited thread"));
newtd->td_flags |= TDF_DIDRUN;
TD_SET_RUNNING(newtd);
- if ((newtd->td_proc->p_flag & P_NOLOAD) == 0)
+ if ((newtd->td_flags & TDF_NOLOAD) == 0)
sched_load_add();
} else {
newtd = choosethread();
@@ -1289,7 +1289,7 @@ sched_add(struct thread *td, int flags)
}
}
- if ((td->td_proc->p_flag & P_NOLOAD) == 0)
+ if ((td->td_flags & TDF_NOLOAD) == 0)
sched_load_add();
runq_add(ts->ts_runq, td, flags);
if (cpu != NOCPU)
@@ -1338,7 +1338,7 @@ sched_add(struct thread *td, int flags)
if (maybe_preempt(td))
return;
}
- if ((td->td_proc->p_flag & P_NOLOAD) == 0)
+ if ((td->td_flags & TDF_NOLOAD) == 0)
sched_load_add();
runq_add(ts->ts_runq, td, flags);
maybe_resched(td);
@@ -1360,7 +1360,7 @@ sched_rem(struct thread *td)
"prio:%d", td->td_priority, KTR_ATTR_LINKED,
sched_tdname(curthread));
- if ((td->td_proc->p_flag & P_NOLOAD) == 0)
+ if ((td->td_flags & TDF_NOLOAD) == 0)
sched_load_rem();
#ifdef SMP
if (ts->ts_runq != &runq)
Modified: head/sys/kern/sched_ule.c
==============================================================================
--- head/sys/kern/sched_ule.c Tue Nov 3 12:52:35 2009 (r198853)
+++ head/sys/kern/sched_ule.c Tue Nov 3 16:46:52 2009 (r198854)
@@ -495,7 +495,7 @@ tdq_load_add(struct tdq *tdq, struct thr
THREAD_LOCK_ASSERT(td, MA_OWNED);
tdq->tdq_load++;
- if ((td->td_proc->p_flag & P_NOLOAD) == 0)
+ if ((td->td_flags & TDF_NOLOAD) == 0)
tdq->tdq_sysload++;
KTR_COUNTER0(KTR_SCHED, "load", tdq->tdq_loadname, tdq->tdq_load);
}
@@ -514,7 +514,7 @@ tdq_load_rem(struct tdq *tdq, struct thr
("tdq_load_rem: Removing with 0 load on queue %d", TDQ_ID(tdq)));
tdq->tdq_load--;
- if ((td->td_proc->p_flag & P_NOLOAD) == 0)
+ if ((td->td_flags & TDF_NOLOAD) == 0)
tdq->tdq_sysload--;
KTR_COUNTER0(KTR_SCHED, "load", tdq->tdq_loadname, tdq->tdq_load);
}
Modified: head/sys/sys/proc.h
==============================================================================
--- head/sys/sys/proc.h Tue Nov 3 12:52:35 2009 (r198853)
+++ head/sys/sys/proc.h Tue Nov 3 16:46:52 2009 (r198854)
@@ -322,7 +322,7 @@ do { \
#define TDF_NEEDSUSPCHK 0x00008000 /* Thread may need to suspend. */
#define TDF_NEEDRESCHED 0x00010000 /* Thread needs to yield. */
#define TDF_NEEDSIGCHK 0x00020000 /* Thread may need signal delivery. */
-#define TDF_UNUSED18 0x00040000 /* --available-- */
+#define TDF_NOLOAD 0x00040000 /* Ignore during load avg calculations. */
#define TDF_UNUSED19 0x00080000 /* Thread is sleeping on a umtx. */
#define TDF_THRWAKEUP 0x00100000 /* Libthr thread must not suspend itself. */
#define TDF_UNUSED21 0x00200000 /* --available-- */
@@ -558,7 +558,7 @@ struct proc {
#define P_ADVLOCK 0x00001 /* Process may hold a POSIX advisory lock. */
#define P_CONTROLT 0x00002 /* Has a controlling terminal. */
#define P_KTHREAD 0x00004 /* Kernel thread (*). */
-#define P_NOLOAD 0x00008 /* Ignore during load avg calculations. */
+#define P_UNUSED0 0x00008 /* available. */
#define P_PPWAIT 0x00010 /* Parent is waiting for child to exec/exit. */
#define P_PROFIL 0x00020 /* Has started profiling. */
#define P_STOPPROF 0x00040 /* Has thread requesting to stop profiling. */
Modified: head/sys/vm/vm_zeroidle.c
==============================================================================
--- head/sys/vm/vm_zeroidle.c Tue Nov 3 12:52:35 2009 (r198853)
+++ head/sys/vm/vm_zeroidle.c Tue Nov 3 16:46:52 2009 (r198854)
@@ -139,26 +139,21 @@ vm_pagezero(void __unused *arg)
}
}
-static struct proc *pagezero_proc;
-
static void
pagezero_start(void __unused *arg)
{
int error;
+ struct proc *p;
struct thread *td;
- error = kproc_create(vm_pagezero, NULL, &pagezero_proc, RFSTOPPED, 0,
- "pagezero");
+ error = kproc_create(vm_pagezero, NULL, &p, RFSTOPPED, 0, "pagezero");
if (error)
panic("pagezero_start: error %d\n", error);
- /*
- * We're an idle task, don't count us in the load.
- */
- PROC_LOCK(pagezero_proc);
- pagezero_proc->p_flag |= P_NOLOAD;
- PROC_UNLOCK(pagezero_proc);
- td = FIRST_THREAD_IN_PROC(pagezero_proc);
+ td = FIRST_THREAD_IN_PROC(p);
thread_lock(td);
+
+ /* We're an idle task, don't count us in the load. */
+ td->td_flags |= TDF_NOLOAD;
sched_class(td, PRI_IDLE);
sched_prio(td, PRI_MAX_IDLE);
sched_add(td, SRQ_BORING);
From alc at FreeBSD.org Tue Nov 3 17:15:16 2009
From: alc at FreeBSD.org (Alan Cox)
Date: Tue Nov 3 17:15:30 2009
Subject: svn commit: r198855 - head/sys/vm
Message-ID: <200911031715.nA3HFG7T097552@svn.freebsd.org>
Author: alc
Date: Tue Nov 3 17:15:15 2009
New Revision: 198855
URL: http://svn.freebsd.org/changeset/base/198855
Log:
Eliminate a bit of hackery from vm_fault(). The operations that this
hackery sought to prevent are now properly supported by vm_map_protect().
(See r198505.)
Reviewed by: kib
Modified:
head/sys/vm/vm_fault.c
Modified: head/sys/vm/vm_fault.c
==============================================================================
--- head/sys/vm/vm_fault.c Tue Nov 3 16:46:52 2009 (r198854)
+++ head/sys/vm/vm_fault.c Tue Nov 3 17:15:15 2009 (r198855)
@@ -264,17 +264,6 @@ RetryFault:;
&fs.entry, &fs.first_object, &fs.first_pindex, &prot, &wired);
if (result != KERN_SUCCESS)
return (result);
-
- /*
- * If we don't COW now, on a user wire, the user will never
- * be able to write to the mapping. If we don't make this
- * restriction, the bookkeeping would be nearly impossible.
- *
- * XXX The following assignment modifies the map without
- * holding a write lock on it.
- */
- if ((fs.entry->protection & VM_PROT_WRITE) == 0)
- fs.entry->max_protection &= ~VM_PROT_WRITE;
}
map_generation = fs.map->timestamp;
From jhb at FreeBSD.org Tue Nov 3 18:40:43 2009
From: jhb at FreeBSD.org (John Baldwin)
Date: Tue Nov 3 18:40:49 2009
Subject: svn commit: r198856 - head/secure/usr.bin/bdes
Message-ID: <200911031840.nA3Iegir099750@svn.freebsd.org>
Author: jhb
Date: Tue Nov 3 18:40:42 2009
New Revision: 198856
URL: http://svn.freebsd.org/changeset/base/198856
Log:
Fix a couple of comment typos.
MFC after: 1 week
Modified:
head/secure/usr.bin/bdes/bdes.c
Modified: head/secure/usr.bin/bdes/bdes.c
==============================================================================
--- head/secure/usr.bin/bdes/bdes.c Tue Nov 3 17:15:15 2009 (r198855)
+++ head/secure/usr.bin/bdes/bdes.c Tue Nov 3 18:40:42 2009 (r198856)
@@ -170,11 +170,11 @@ main(int argc, char *argv[])
int i; /* counter in a for loop */
char *p; /* used to obtain the key */
DES_cblock msgbuf; /* I/O buffer */
- int kflag; /* command-line encryptiooon key */
+ int kflag; /* command-line encryption key */
setproctitle("-"); /* Hide command-line arguments */
- /* initialize the initialization vctor */
+ /* initialize the initialization vector */
MEMZERO(ivec, 8);
/* process the argument list */
From jh at FreeBSD.org Tue Nov 3 19:05:06 2009
From: jh at FreeBSD.org (Jaakko Heinonen)
Date: Tue Nov 3 19:05:17 2009
Subject: svn commit: r198857 - head/sys/dev/fdc
Message-ID: <200911031905.nA3J55Wo000741@svn.freebsd.org>
Author: jh
Date: Tue Nov 3 19:05:05 2009
New Revision: 198857
URL: http://svn.freebsd.org/changeset/base/198857
Log:
fdc(4) module unload fixes:
- Tear down the interrupt handler before killing the worker thread.
- Do geom withering as GEOM event to avoid acquiring the GEOM topology
lock under Giant.
PR: kern/104079
Reviewed by: joerg
Approved by: trasz (mentor)
Modified:
head/sys/dev/fdc/fdc.c
Modified: head/sys/dev/fdc/fdc.c
==============================================================================
--- head/sys/dev/fdc/fdc.c Tue Nov 3 18:40:42 2009 (r198856)
+++ head/sys/dev/fdc/fdc.c Tue Nov 3 19:05:05 2009 (r198857)
@@ -1734,6 +1734,10 @@ fdc_detach(device_t dev)
if ((error = bus_generic_detach(dev)))
return (error);
+ if (fdc->fdc_intr)
+ bus_teardown_intr(dev, fdc->res_irq, fdc->fdc_intr);
+ fdc->fdc_intr = NULL;
+
/* kill worker thread */
mtx_lock(&fdc->fdc_mtx);
fdc->flags |= FDC_KTHREAD_EXIT;
@@ -2031,15 +2035,22 @@ fd_attach(device_t dev)
return (0);
}
+static void
+fd_detach_geom(void *arg, int flag)
+{
+ struct fd_data *fd = arg;
+
+ g_topology_assert();
+ g_wither_geom(fd->fd_geom, ENXIO);
+}
+
static int
fd_detach(device_t dev)
{
struct fd_data *fd;
fd = device_get_softc(dev);
- g_topology_lock();
- g_wither_geom(fd->fd_geom, ENXIO);
- g_topology_unlock();
+ g_waitfor_event(fd_detach_geom, fd, M_WAITOK, NULL);
while (device_get_state(dev) == DS_BUSY)
tsleep(fd, PZERO, "fdd", hz/10);
callout_drain(&fd->toffhandle);
From tom at tomjudge.com Tue Nov 3 19:30:36 2009
From: tom at tomjudge.com (Tom Judge)
Date: Tue Nov 3 19:30:43 2009
Subject: svn commit: r198320 - in head/sys: conf dev/bce
In-Reply-To: <200910211247.n9LCl9Ab099426@svn.freebsd.org>
References: <200910211247.n9LCl9Ab099426@svn.freebsd.org>
Message-ID: <4AF08495.5040507@tomjudge.com>
Hi Stanislav,
Any chance this can be MFC'd to stable/8, stable/7 and releng/8.0?
Tom
Stanislav Sedov wrote:
> Author: stas
> Date: Wed Oct 21 12:47:09 2009
> New Revision: 198320
> URL: http://svn.freebsd.org/changeset/base/198320
>
> Log:
> - Introduce new option BCE_JUMBO_HDRSPLIT that allows user to enable header
> splitting in bce(4) instead of (ab)using ZERO_COPY_SOCKETS that was not
> propagated into if_bce.c anyway. It is disabled by default.
>
> Approved by: davidch
> MFC after: 3 days
>
> Modified:
> head/sys/conf/NOTES
> head/sys/conf/options
> head/sys/dev/bce/if_bce.c
> head/sys/dev/bce/if_bcereg.h
>
> Modified: head/sys/conf/NOTES
> ==============================================================================
> --- head/sys/conf/NOTES Wed Oct 21 12:42:25 2009 (r198319)
> +++ head/sys/conf/NOTES Wed Oct 21 12:47:09 2009 (r198320)
> @@ -1985,6 +1985,12 @@ device lmc
> # only works for Tigon II chips, and has no effect for Tigon I chips.
> options TI_JUMBO_HDRSPLIT
>
> +#
> +# Use header splitting feature on bce(4) adapters.
> +# This may help to reduce the amount of jumbo-sized memory buffers used.
> +#
> +options BCE_JUMBO_HDRSPLIT
> +
> # These two options allow manipulating the mbuf cluster size and mbuf size,
> # respectively. Be very careful with NIC driver modules when changing
> # these from their default values, because that can potentially cause a
>
> Modified: head/sys/conf/options
> ==============================================================================
> --- head/sys/conf/options Wed Oct 21 12:42:25 2009 (r198319)
> +++ head/sys/conf/options Wed Oct 21 12:47:09 2009 (r198320)
> @@ -511,6 +511,7 @@ DRM_DEBUG opt_drm.h
> ZERO_COPY_SOCKETS opt_zero.h
> TI_PRIVATE_JUMBOS opt_ti.h
> TI_JUMBO_HDRSPLIT opt_ti.h
> +BCE_JUMBO_HDRSPLIT opt_bce.h
>
> # XXX Conflict: # of devices vs network protocol (Native ATM).
> # This makes "atm.h" unusable.
>
> Modified: head/sys/dev/bce/if_bce.c
> ==============================================================================
> --- head/sys/dev/bce/if_bce.c Wed Oct 21 12:42:25 2009 (r198319)
> +++ head/sys/dev/bce/if_bce.c Wed Oct 21 12:47:09 2009 (r198320)
> @@ -293,12 +293,12 @@ static void bce_dump_enet (str
> static void bce_dump_mbuf (struct bce_softc *, struct mbuf *);
> static void bce_dump_tx_mbuf_chain (struct bce_softc *, u16, int);
> static void bce_dump_rx_mbuf_chain (struct bce_softc *, u16, int);
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> static void bce_dump_pg_mbuf_chain (struct bce_softc *, u16, int);
> #endif
> static void bce_dump_txbd (struct bce_softc *, int, struct tx_bd *);
> static void bce_dump_rxbd (struct bce_softc *, int, struct rx_bd *);
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> static void bce_dump_pgbd (struct bce_softc *, int, struct rx_bd *);
> #endif
> static void bce_dump_l2fhdr (struct bce_softc *, int, struct l2_fhdr *);
> @@ -306,7 +306,7 @@ static void bce_dump_ctx (struct bce_s
> static void bce_dump_ftqs (struct bce_softc *);
> static void bce_dump_tx_chain (struct bce_softc *, u16, int);
> static void bce_dump_rx_chain (struct bce_softc *, u16, int);
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> static void bce_dump_pg_chain (struct bce_softc *, u16, int);
> #endif
> static void bce_dump_status_block (struct bce_softc *);
> @@ -393,7 +393,7 @@ static int bce_init_rx_chain (struct b
> static void bce_fill_rx_chain (struct bce_softc *);
> static void bce_free_rx_chain (struct bce_softc *);
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> static int bce_get_pg_buf (struct bce_softc *, struct mbuf *, u16 *, u16 *);
> static int bce_init_pg_chain (struct bce_softc *);
> static void bce_fill_pg_chain (struct bce_softc *);
> @@ -602,7 +602,7 @@ bce_print_adapter_info(struct bce_softc
> /* Firmware version and device features. */
> printf("B/C (%s); Flags (", sc->bce_bc_ver);
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> printf("SPLT ");
> i++;
> #endif
> @@ -1066,7 +1066,7 @@ bce_attach(device_t dev)
> * This may change later if the MTU size is set to
> * something other than 1500.
> */
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> sc->rx_bd_mbuf_alloc_size = MHLEN;
> /* Make sure offset is 16 byte aligned for hardware. */
> sc->rx_bd_mbuf_align_pad = roundup2((MSIZE - MHLEN), 16) -
> @@ -2835,7 +2835,7 @@ bce_dma_free(struct bce_softc *sc)
> }
>
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /* Free, unmap and destroy all page buffer descriptor chain pages. */
> for (i = 0; i < PG_PAGES; i++ ) {
> if (sc->pg_bd_chain[i] != NULL) {
> @@ -2899,7 +2899,7 @@ bce_dma_free(struct bce_softc *sc)
> sc->rx_mbuf_tag = NULL;
> }
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /* Unload and destroy the page mbuf maps. */
> for (i = 0; i < TOTAL_PG_BD; i++) {
> if (sc->pg_mbuf_map[i] != NULL) {
> @@ -3345,7 +3345,7 @@ bce_dma_alloc(device_t dev)
> /*
> * Create a DMA tag for RX mbufs.
> */
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> max_size = max_seg_size = ((sc->rx_bd_mbuf_alloc_size < MCLBYTES) ?
> MCLBYTES : sc->rx_bd_mbuf_alloc_size);
> #else
> @@ -3386,7 +3386,7 @@ bce_dma_alloc(device_t dev)
> }
> }
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /*
> * Create a DMA tag for the page buffer descriptor chain,
> * allocate and clear the memory, and fetch the physical
> @@ -4473,7 +4473,7 @@ bce_stop(struct bce_softc *sc)
> bce_disable_intr(sc);
>
> /* Free RX buffers. */
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> bce_free_pg_chain(sc);
> #endif
> bce_free_rx_chain(sc);
> @@ -4910,7 +4910,7 @@ bce_get_rx_buf(struct bce_softc *sc, str
> goto bce_get_rx_buf_exit);
>
> /* This is a new mbuf allocation. */
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> MGETHDR(m_new, M_DONTWAIT, MT_DATA);
> #else
> if (sc->rx_bd_mbuf_alloc_size <= MCLBYTES)
> @@ -4991,7 +4991,7 @@ bce_get_rx_buf_exit:
> }
>
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /****************************************************************************/
> /* Encapsulate an mbuf cluster into the page chain. */
> /* */
> @@ -5100,7 +5100,7 @@ bce_get_pg_buf_exit:
>
> return(rc);
> }
> -#endif /* ZERO_COPY_SOCKETS */
> +#endif /* BCE_JUMBO_HDRSPLIT */
>
> /****************************************************************************/
> /* Initialize the TX context memory. */
> @@ -5456,7 +5456,7 @@ bce_free_rx_chain(struct bce_softc *sc)
> }
>
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /****************************************************************************/
> /* Allocate memory and initialize the page data structures. */
> /* Assumes that bce_init_rx_chain() has not already been called. */
> @@ -5620,7 +5620,7 @@ bce_free_pg_chain(struct bce_softc *sc)
>
> DBEXIT(BCE_VERBOSE_RESET | BCE_VERBOSE_RECV | BCE_VERBOSE_UNLOAD);
> }
> -#endif /* ZERO_COPY_SOCKETS */
> +#endif /* BCE_JUMBO_HDRSPLIT */
>
>
> /****************************************************************************/
> @@ -5793,7 +5793,7 @@ bce_rx_intr(struct bce_softc *sc)
> unsigned int pkt_len;
> u16 sw_rx_cons, sw_rx_cons_idx, hw_rx_cons;
> u32 status;
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> unsigned int rem_len;
> u16 sw_pg_cons, sw_pg_cons_idx;
> #endif
> @@ -5809,7 +5809,7 @@ bce_rx_intr(struct bce_softc *sc)
> bus_dmamap_sync(sc->rx_bd_chain_tag,
> sc->rx_bd_chain_map[i], BUS_DMASYNC_POSTREAD);
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /* Prepare the page chain pages to be accessed by the host CPU. */
> for (int i = 0; i < PG_PAGES; i++)
> bus_dmamap_sync(sc->pg_bd_chain_tag,
> @@ -5821,7 +5821,7 @@ bce_rx_intr(struct bce_softc *sc)
>
> /* Get working copies of the driver's view of the consumer indices. */
> sw_rx_cons = sc->rx_cons;
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> sw_pg_cons = sc->pg_cons;
> #endif
>
> @@ -5882,7 +5882,7 @@ bce_rx_intr(struct bce_softc *sc)
> */
> m_adj(m0, sizeof(struct l2_fhdr) + ETHER_ALIGN);
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /*
> * Check whether the received frame fits in a single
> * mbuf or not (i.e. packet data + FCS <=
> @@ -6056,7 +6056,7 @@ bce_rx_int_next_rx:
> if (m0) {
> /* Make sure we don't lose our place when we release the lock. */
> sc->rx_cons = sw_rx_cons;
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> sc->pg_cons = sw_pg_cons;
> #endif
>
> @@ -6066,7 +6066,7 @@ bce_rx_int_next_rx:
>
> /* Recover our place. */
> sw_rx_cons = sc->rx_cons;
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> sw_pg_cons = sc->pg_cons;
> #endif
> }
> @@ -6077,7 +6077,7 @@ bce_rx_int_next_rx:
> }
>
> /* No new packets to process. Refill the RX and page chains and exit. */
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> sc->pg_cons = sw_pg_cons;
> bce_fill_pg_chain(sc);
> #endif
> @@ -6090,7 +6090,7 @@ bce_rx_int_next_rx:
> bus_dmamap_sync(sc->rx_bd_chain_tag,
> sc->rx_bd_chain_map[i], BUS_DMASYNC_PREWRITE);
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> for (int i = 0; i < PG_PAGES; i++)
> bus_dmamap_sync(sc->pg_bd_chain_tag,
> sc->pg_bd_chain_map[i], BUS_DMASYNC_PREWRITE);
> @@ -6336,7 +6336,7 @@ bce_init_locked(struct bce_softc *sc)
> * Calculate and program the hardware Ethernet MTU
> * size. Be generous on the receive if we have room.
> */
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> if (ifp->if_mtu <= (sc->rx_bd_mbuf_data_len + sc->pg_bd_mbuf_alloc_size))
> ether_mtu = sc->rx_bd_mbuf_data_len + sc->pg_bd_mbuf_alloc_size;
> #else
> @@ -6368,7 +6368,7 @@ bce_init_locked(struct bce_softc *sc)
> /* Program appropriate promiscuous/multicast filtering. */
> bce_set_rx_mode(sc);
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> DBPRINT(sc, BCE_INFO_LOAD, "%s(): pg_bd_mbuf_alloc_size = %d\n",
> __FUNCTION__, sc->pg_bd_mbuf_alloc_size);
>
> @@ -6881,7 +6881,7 @@ bce_ioctl(struct ifnet *ifp, u_long comm
> BCE_LOCK(sc);
> ifp->if_mtu = ifr->ifr_mtu;
> ifp->if_drv_flags &= ~IFF_DRV_RUNNING;
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /* No buffer allocation size changes are necessary. */
> #else
> /* Recalculate our buffer allocation sizes. */
> @@ -7584,7 +7584,7 @@ bce_tick(void *xsc)
> bce_stats_update(sc);
>
> /* Top off the receive and page chains. */
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> bce_fill_pg_chain(sc);
> #endif
> bce_fill_rx_chain(sc);
> @@ -7764,7 +7764,7 @@ bce_sysctl_dump_tx_chain(SYSCTL_HANDLER_
> }
>
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /****************************************************************************/
> /* Provides a sysctl interface to allow dumping the page chain. */
> /* */
> @@ -8392,7 +8392,7 @@ bce_add_sysctls(struct bce_softc *sc)
> (void *)sc, 0,
> bce_sysctl_dump_tx_chain, "I", "Dump tx_bd chain");
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> SYSCTL_ADD_PROC(ctx, children, OID_AUTO,
> "dump_pg_chain", CTLTYPE_INT | CTLFLAG_RW,
> (void *)sc, 0,
> @@ -8687,7 +8687,7 @@ bce_dump_rx_mbuf_chain(struct bce_softc
> }
>
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /****************************************************************************/
> /* Prints out the mbufs in the mbuf page chain. */
> /* */
> @@ -8811,7 +8811,7 @@ bce_dump_rxbd(struct bce_softc *sc, int
> }
>
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /****************************************************************************/
> /* Prints out a rx_bd structure in the page chain. */
> /* */
> @@ -9298,7 +9298,7 @@ bce_dump_rx_chain(struct bce_softc *sc,
> }
>
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /****************************************************************************/
> /* Prints out the page chain. */
> /* */
> @@ -9779,7 +9779,7 @@ bce_dump_driver_state(struct bce_softc *
> "0x%08X:%08X - (sc->rx_bd_chain) rx_bd chain virtual address\n",
> val_hi, val_lo);
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> val_hi = BCE_ADDR_HI(sc->pg_bd_chain);
> val_lo = BCE_ADDR_LO(sc->pg_bd_chain);
> BCE_PRINTF(
> @@ -9799,7 +9799,7 @@ bce_dump_driver_state(struct bce_softc *
> "0x%08X:%08X - (sc->rx_mbuf_ptr) rx mbuf chain virtual address\n",
> val_hi, val_lo);
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> val_hi = BCE_ADDR_HI(sc->pg_mbuf_ptr);
> val_lo = BCE_ADDR_LO(sc->pg_mbuf_ptr);
> BCE_PRINTF(
> @@ -9852,7 +9852,7 @@ bce_dump_driver_state(struct bce_softc *
> BCE_PRINTF(" 0x%08X - (sc->free_rx_bd) free rx_bd's\n",
> sc->free_rx_bd);
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> BCE_PRINTF(" 0x%04X(0x%04X) - (sc->pg_prod) page producer index\n",
> sc->pg_prod, (u16) PG_CHAIN_IDX(sc->pg_prod));
>
> @@ -10358,7 +10358,7 @@ bce_breakpoint(struct bce_softc *sc)
> bce_dump_tpat_state(sc, 0);
> bce_dump_cp_state(sc, 0);
> bce_dump_com_state(sc, 0);
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> bce_dump_pgbd(sc, 0, NULL);
> bce_dump_pg_mbuf_chain(sc, 0, USABLE_PG_BD);
> bce_dump_pg_chain(sc, 0, USABLE_PG_BD);
>
> Modified: head/sys/dev/bce/if_bcereg.h
> ==============================================================================
> --- head/sys/dev/bce/if_bcereg.h Wed Oct 21 12:42:25 2009 (r198319)
> +++ head/sys/dev/bce/if_bcereg.h Wed Oct 21 12:47:09 2009 (r198320)
> @@ -6216,7 +6216,7 @@ struct l2_fhdr {
> #define RX_PAGE(x) (((x) & ~USABLE_RX_BD_PER_PAGE) >> (BCM_PAGE_BITS - 4))
> #define RX_IDX(x) ((x) & USABLE_RX_BD_PER_PAGE)
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /*
> * To accomodate jumbo frames, the page chain should
> * be 4 times larger than the receive chain.
> @@ -6238,7 +6238,7 @@ struct l2_fhdr {
> #define PG_PAGE(x) (((x) & ~USABLE_PG_BD_PER_PAGE) >> (BCM_PAGE_BITS - 4))
> #define PG_IDX(x) ((x) & USABLE_PG_BD_PER_PAGE)
>
> -#endif /* ZERO_COPY_SOCKETS */
> +#endif /* BCE_JUMBO_HDRSPLIT */
>
> #define CTX_INIT_RETRY_COUNT 10
>
> @@ -6517,7 +6517,7 @@ struct bce_softc
> u16 tx_cons;
> u32 tx_prod_bseq; /* Counts the bytes used. */
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> u16 pg_prod;
> u16 pg_cons;
> #endif
> @@ -6534,7 +6534,7 @@ struct bce_softc
> int rx_bd_mbuf_data_len;
> int rx_bd_mbuf_align_pad;
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> int pg_bd_mbuf_alloc_size;
> #endif
>
> @@ -6556,7 +6556,7 @@ struct bce_softc
> struct rx_bd *rx_bd_chain[RX_PAGES];
> bus_addr_t rx_bd_chain_paddr[RX_PAGES];
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /* H/W maintained page buffer descriptor chain structure. */
> bus_dma_tag_t pg_bd_chain_tag;
> bus_dmamap_t pg_bd_chain_map[PG_PAGES];
> @@ -6593,7 +6593,7 @@ struct bce_softc
> bus_dma_tag_t rx_mbuf_tag;
> bus_dma_tag_t tx_mbuf_tag;
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> bus_dma_tag_t pg_mbuf_tag;
> #endif
>
> @@ -6605,7 +6605,7 @@ struct bce_softc
> bus_dmamap_t rx_mbuf_map[TOTAL_RX_BD];
> struct mbuf *rx_mbuf_ptr[TOTAL_RX_BD];
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> /* S/W maintained mbuf page chain structure. */
> bus_dmamap_t pg_mbuf_map[TOTAL_PG_BD];
> struct mbuf *pg_mbuf_ptr[TOTAL_PG_BD];
> @@ -6617,7 +6617,7 @@ struct bce_softc
> u16 used_tx_bd;
> u16 max_tx_bd;
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> u16 free_pg_bd;
> u16 max_pg_bd;
> #endif
> @@ -6705,7 +6705,7 @@ struct bce_softc
> int debug_tx_mbuf_alloc;
> int debug_rx_mbuf_alloc;
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> int debug_pg_mbuf_alloc;
> #endif
>
> @@ -6722,7 +6722,7 @@ struct bce_softc
> u32 rx_low_watermark; /* Lowest number of rx_bd's free. */
> u32 rx_empty_count; /* Number of times the RX chain was empty. */
>
> -#ifdef ZERO_COPY_SOCKETS
> +#ifdef BCE_JUMBO_HDRSPLIT
> u32 pg_low_watermark; /* Lowest number of pages free. */
> u32 pg_empty_count; /* Number of times the page chain was empty. */
> #endif
> _______________________________________________
> svn-src-all@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/svn-src-all
> To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
From jkim at FreeBSD.org Tue Nov 3 20:22:09 2009
From: jkim at FreeBSD.org (Jung-uk Kim)
Date: Tue Nov 3 20:22:21 2009
Subject: svn commit: r198858 - in head/sys: dev/fb dev/syscons sys
Message-ID: <200911032022.nA3KM96H003434@svn.freebsd.org>
Author: jkim
Date: Tue Nov 3 20:22:09 2009
New Revision: 198858
URL: http://svn.freebsd.org/changeset/base/198858
Log:
Fix VESA color palette corruption:
- VBE 3.0 says palette format resets to 6-bit mode when video mode changes.
We simply set 8-bit mode when we switch modes if the adapter supports it.
- VBE 3.0 also says if the mode is not VGA compatible, we must use VBE
function to save/restore palette. Otherwise, VGA function may be used.
Thus, reinstate the save/load palette functions only for non-VGA compatible
modes regardless of its palette format.
- Let vesa(4) set VESA modes even if vga(4) claims to support it.
- Reset default palette if VESA pixel mode is set initially.
- Fix more style nits.
Modified:
head/sys/dev/fb/vesa.c
head/sys/dev/syscons/syscons.c
head/sys/sys/fbio.h
Modified: head/sys/dev/fb/vesa.c
==============================================================================
--- head/sys/dev/fb/vesa.c Tue Nov 3 19:05:05 2009 (r198857)
+++ head/sys/dev/fb/vesa.c Tue Nov 3 20:22:09 2009 (r198858)
@@ -174,10 +174,8 @@ static int vesa_bios_save_palette2(int s
u_char *b, int bits);
static int vesa_bios_load_palette(int start, int colors, u_char *palette,
int bits);
-#ifdef notyet
static int vesa_bios_load_palette2(int start, int colors, u_char *r, u_char *g,
u_char *b, int bits);
-#endif
#define STATE_SIZE 0
#define STATE_SAVE 1
#define STATE_LOAD 2
@@ -415,9 +413,9 @@ vesa_bios_save_palette(int start, int co
bits = 8 - bits;
for (i = 0; i < colors; ++i) {
- palette[i*3] = p[i*4 + 2] << bits;
- palette[i*3 + 1] = p[i*4 + 1] << bits;
- palette[i*3 + 2] = p[i*4] << bits;
+ palette[i * 3] = p[i * 4 + 2] << bits;
+ palette[i * 3 + 1] = p[i * 4 + 1] << bits;
+ palette[i * 3 + 2] = p[i * 4] << bits;
}
x86bios_free(p, colors * 4);
@@ -455,9 +453,9 @@ vesa_bios_save_palette2(int start, int c
bits = 8 - bits;
for (i = 0; i < colors; ++i) {
- r[i] = p[i*4 + 2] << bits;
- g[i] = p[i*4 + 1] << bits;
- b[i] = p[i*4] << bits;
+ r[i] = p[i * 4 + 2] << bits;
+ g[i] = p[i * 4 + 1] << bits;
+ b[i] = p[i * 4] << bits;
}
x86bios_free(p, colors * 4);
@@ -487,10 +485,10 @@ vesa_bios_load_palette(int start, int co
bits = 8 - bits;
for (i = 0; i < colors; ++i) {
- p[i*4] = palette[i*3 + 2] >> bits;
- p[i*4 + 1] = palette[i*3 + 1] >> bits;
- p[i*4 + 2] = palette[i*3] >> bits;
- p[i*4 + 3] = 0;
+ p[i * 4] = palette[i * 3 + 2] >> bits;
+ p[i * 4 + 1] = palette[i * 3 + 1] >> bits;
+ p[i * 4 + 2] = palette[i * 3] >> bits;
+ p[i * 4 + 3] = 0;
}
x86bios_intr(®s, 0x10);
x86bios_free(p, colors * 4);
@@ -498,7 +496,6 @@ vesa_bios_load_palette(int start, int co
return (regs.R_AX != 0x004f);
}
-#ifdef notyet
static int
vesa_bios_load_palette2(int start, int colors, u_char *r, u_char *g, u_char *b,
int bits)
@@ -523,17 +520,16 @@ vesa_bios_load_palette2(int start, int c
bits = 8 - bits;
for (i = 0; i < colors; ++i) {
- p[i*4] = b[i] >> bits;
- p[i*4 + 1] = g[i] >> bits;
- p[i*4 + 2] = r[i] >> bits;
- p[i*4 + 3] = 0;
+ p[i * 4] = b[i] >> bits;
+ p[i * 4 + 1] = g[i] >> bits;
+ p[i * 4 + 2] = r[i] >> bits;
+ p[i * 4 + 3] = 0;
}
x86bios_intr(®s, 0x10);
x86bios_free(p, colors * 4);
return (regs.R_AX != 0x004f);
}
-#endif
static ssize_t
vesa_bios_state_buf_size(void)
@@ -702,6 +698,7 @@ vesa_translate_flags(u_int16_t vflags)
{ V_MODECOLOR, V_INFO_COLOR, 0 },
{ V_MODEGRAPHICS, V_INFO_GRAPHICS, 0 },
{ V_MODELFB, V_INFO_LINEAR, 0 },
+ { V_MODENONVGA, V_INFO_NONVGA, 0 },
};
int flags;
int i;
@@ -1275,7 +1272,8 @@ vesa_set_mode(video_adapter_t *adp, int
* the new mode correctly.
*/
if (VESA_MODE(adp->va_mode)) {
- if ((*prevvidsw->get_info)(adp, mode, &info) == 0) {
+ if (!VESA_MODE(mode) &&
+ (*prevvidsw->get_info)(adp, mode, &info) == 0) {
int10_set_mode(adp->va_initial_bios_mode);
if (adp->va_info.vi_flags & V_INFO_LINEAR)
vesa_unmap_buffer(adp->va_buffer,
@@ -1288,7 +1286,7 @@ vesa_set_mode(video_adapter_t *adp, int
}
/* we may not need to handle this mode after all... */
- if ((*prevvidsw->set_mode)(adp, mode) == 0)
+ if (!VESA_MODE(mode) && (*prevvidsw->set_mode)(adp, mode) == 0)
return (0);
/* is the new mode supported? */
@@ -1306,6 +1304,9 @@ vesa_set_mode(video_adapter_t *adp, int
if (vesa_bios_set_mode(mode | ((info.vi_flags & V_INFO_LINEAR) ? 0x4000 : 0)))
return (1);
+ if ((vesa_adp_info->v_flags & V_DAC8) != 0)
+ vesa_bios_set_dac(8);
+
if (adp->va_info.vi_flags & V_INFO_LINEAR)
vesa_unmap_buffer(adp->va_buffer,
vesa_adp_info->v_memsize*64*1024);
@@ -1382,17 +1383,11 @@ static int
vesa_save_palette(video_adapter_t *adp, u_char *palette)
{
int bits;
- int error;
- if ((adp == vesa_adp) && (vesa_adp_info->v_flags & V_DAC8)
- && VESA_MODE(adp->va_mode)) {
- bits = vesa_bios_get_dac();
- error = vesa_bios_save_palette(0, 256, palette, bits);
- if (error == 0)
- return (0);
- if (bits != 6)
- return (error);
- }
+ if ((adp == vesa_adp) &&
+ (adp->va_info.vi_flags & V_INFO_NONVGA) != 0 &&
+ (bits = vesa_bios_get_dac()) >= 6)
+ return (vesa_bios_save_palette(0, 256, palette, bits));
return ((*prevvidsw->save_palette)(adp, palette));
}
@@ -1400,19 +1395,12 @@ vesa_save_palette(video_adapter_t *adp,
static int
vesa_load_palette(video_adapter_t *adp, u_char *palette)
{
-#ifdef notyet
int bits;
- int error;
- if ((adp == vesa_adp) && (vesa_adp_info->v_flags & V_DAC8)
- && VESA_MODE(adp->va_mode) && ((bits = vesa_bios_set_dac(8)) > 6)) {
- error = vesa_bios_load_palette(0, 256, palette, bits);
- if (error == 0)
- return (0);
- if (vesa_bios_set_dac(6) != 6)
- return (1);
- }
-#endif /* notyet */
+ if ((adp == vesa_adp) &&
+ (adp->va_info.vi_flags & V_INFO_NONVGA) != 0 &&
+ (bits = vesa_bios_get_dac()) >= 6)
+ return (vesa_bios_load_palette(0, 256, palette, bits));
return ((*prevvidsw->load_palette)(adp, palette));
}
@@ -1637,14 +1625,11 @@ get_palette(video_adapter_t *adp, int ba
return (1);
if ((base + count) > 256)
return (1);
- if (!(vesa_adp_info->v_flags & V_DAC8) || !VESA_MODE(adp->va_mode))
+ if ((adp->va_info.vi_flags & V_INFO_NONVGA) == 0 ||
+ (bits = vesa_bios_get_dac()) < 6)
return (1);
- bits = vesa_bios_get_dac();
- if (bits <= 6)
- return (1);
-
- r = malloc(count*3, M_DEVBUF, M_WAITOK);
+ r = malloc(count * 3, M_DEVBUF, M_WAITOK);
g = r + count;
b = g + count;
error = vesa_bios_save_palette2(base, count, r, g, b, bits);
@@ -1659,7 +1644,6 @@ get_palette(video_adapter_t *adp, int ba
}
free(r, M_DEVBUF);
- /* if error && bits != 6 at this point, we are in trouble... XXX */
return (error);
}
@@ -1667,8 +1651,6 @@ static int
set_palette(video_adapter_t *adp, int base, int count,
u_char *red, u_char *green, u_char *blue, u_char *trans)
{
- return (1);
-#ifdef notyet
u_char *r;
u_char *g;
u_char *b;
@@ -1677,11 +1659,11 @@ set_palette(video_adapter_t *adp, int ba
if ((base < 0) || (base >= 256) || (base + count > 256))
return (1);
- if (!(vesa_adp_info->v_flags & V_DAC8) || !VESA_MODE(adp->va_mode)
- || ((bits = vesa_bios_set_dac(8)) <= 6))
+ if ((adp->va_info.vi_flags & V_INFO_NONVGA) == 0 ||
+ (bits = vesa_bios_get_dac()) < 6)
return (1);
- r = malloc(count*3, M_DEVBUF, M_WAITOK);
+ r = malloc(count * 3, M_DEVBUF, M_WAITOK);
g = r + count;
b = g + count;
copyin(red, r, count);
@@ -1690,13 +1672,8 @@ set_palette(video_adapter_t *adp, int ba
error = vesa_bios_load_palette2(base, count, r, g, b, bits);
free(r, M_DEVBUF);
- if (error == 0)
- return (0);
- /* if the following call fails, we are in trouble... XXX */
- vesa_bios_set_dac(6);
- return (1);
-#endif /* notyet */
+ return (error);
}
static int
Modified: head/sys/dev/syscons/syscons.c
==============================================================================
--- head/sys/dev/syscons/syscons.c Tue Nov 3 19:05:05 2009 (r198857)
+++ head/sys/dev/syscons/syscons.c Tue Nov 3 20:22:09 2009 (r198858)
@@ -414,6 +414,9 @@ sc_attach_unit(int unit, int flags)
#endif
sc_set_graphics_mode(scp, NULL, vmode);
sc_set_pixel_mode(scp, NULL, 0, 0, 16, 8);
+#ifndef SC_NO_PALETTE_LOADING
+ vidd_save_palette(sc->adp, sc->palette);
+#endif
sc->initial_mode = vmode;
#ifdef DEV_SPLASH
/* put up the splash again! */
Modified: head/sys/sys/fbio.h
==============================================================================
--- head/sys/sys/fbio.h Tue Nov 3 19:05:05 2009 (r198857)
+++ head/sys/sys/fbio.h Tue Nov 3 20:22:09 2009 (r198858)
@@ -269,6 +269,7 @@ struct video_info {
#define V_INFO_GRAPHICS (1 << 1)
#define V_INFO_LINEAR (1 << 2)
#define V_INFO_VESA (1 << 3)
+#define V_INFO_NONVGA (1 << 4)
int vi_width;
int vi_height;
int vi_cwidth;
From thompsa at FreeBSD.org Tue Nov 3 21:06:19 2009
From: thompsa at FreeBSD.org (Andrew Thompson)
Date: Tue Nov 3 21:06:37 2009
Subject: svn commit: r198859 - head
Message-ID: <200911032106.nA3L6JCn004918@svn.freebsd.org>
Author: thompsa
Date: Tue Nov 3 21:06:19 2009
New Revision: 198859
URL: http://svn.freebsd.org/changeset/base/198859
Log:
Belatedly add an UPDATING message for the usb ethernet ifnet naming in r188412.
MFC after: 3 days
Modified:
head/UPDATING
Modified: head/UPDATING
==============================================================================
--- head/UPDATING Tue Nov 3 20:22:09 2009 (r198858)
+++ head/UPDATING Tue Nov 3 21:06:19 2009 (r198859)
@@ -537,6 +537,11 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 9.
# Map old usb library to new one for usb2 stack
libusb-0.1.so.8 libusb20.so.1
+20090209:
+ All USB ethernet devices now attach as interfaces under the name ueN
+ (eg. ue0). This is to provide a predictable name as vendors often
+ change usb chipsets in a product without notice.
+
20090203:
The ichsmb(4) driver has been changed to require SMBus slave
addresses be left-justified (xxxxxxx0b) rather than right-justified.
From ed at FreeBSD.org Tue Nov 3 21:06:20 2009
From: ed at FreeBSD.org (Ed Schouten)
Date: Tue Nov 3 21:06:37 2009
Subject: svn commit: r198860 - in head/sys: kern sys
Message-ID: <200911032106.nA3L6Jhq004939@svn.freebsd.org>
Author: ed
Date: Tue Nov 3 21:06:19 2009
New Revision: 198860
URL: http://svn.freebsd.org/changeset/base/198860
Log:
Make /dev/klog and kern.msgbuf* MPSAFE.
Normally msgbufp is locked using Giant. Switch it to use the
msgbuf_lock. Instead of changing the tsleep() calls to msleep(), just
convert it to condvar(9).
In my opinion the locking around msgbuf_peekbytes() still remains
questionable. It looks like locks are dropped while performing copies of
multiple blocks to userspace, which may cause the msgbuf to be reset in
the mean time. At least getting it underneath from Giant should make it
a little easier for us to figure out how to solve that.
Reminded by: rdivacky
Modified:
head/sys/kern/subr_log.c
head/sys/kern/subr_prf.c
head/sys/sys/msgbuf.h
Modified: head/sys/kern/subr_log.c
==============================================================================
--- head/sys/kern/subr_log.c Tue Nov 3 21:06:19 2009 (r198859)
+++ head/sys/kern/subr_log.c Tue Nov 3 21:06:19 2009 (r198860)
@@ -53,7 +53,6 @@ __FBSDID("$FreeBSD$");
#define LOG_RDPRI (PZERO + 1)
#define LOG_ASYNC 0x04
-#define LOG_RDWAIT 0x08
static d_open_t logopen;
static d_close_t logclose;
@@ -65,7 +64,6 @@ static void logtimeout(void *arg);
static struct cdevsw log_cdevsw = {
.d_version = D_VERSION,
- .d_flags = D_NEEDGIANT,
.d_open = logopen,
.d_close = logclose,
.d_read = logread,
@@ -81,7 +79,10 @@ static struct logsoftc {
struct callout sc_callout; /* callout to wakeup syslog */
} logsoftc;
-int log_open; /* also used in log() */
+int log_open; /* also used in log() */
+static struct cv log_wakeup;
+struct mtx msgbuf_lock;
+MTX_SYSINIT(msgbuf_lock, &msgbuf_lock, "msgbuf lock", MTX_DEF);
/* Times per second to check for a pending syslog wakeup. */
static int log_wakeups_per_second = 5;
@@ -92,17 +93,23 @@ SYSCTL_INT(_kern, OID_AUTO, log_wakeups_
static int
logopen(struct cdev *dev, int flags, int mode, struct thread *td)
{
- if (log_open)
- return (EBUSY);
- log_open = 1;
- callout_init(&logsoftc.sc_callout, 0);
- fsetown(td->td_proc->p_pid, &logsoftc.sc_sigio); /* signal process only */
+
if (log_wakeups_per_second < 1) {
printf("syslog wakeup is less than one. Adjusting to 1.\n");
log_wakeups_per_second = 1;
}
+
+ mtx_lock(&msgbuf_lock);
+ if (log_open) {
+ mtx_unlock(&msgbuf_lock);
+ return (EBUSY);
+ }
+ log_open = 1;
callout_reset(&logsoftc.sc_callout, hz / log_wakeups_per_second,
logtimeout, NULL);
+ mtx_unlock(&msgbuf_lock);
+
+ fsetown(td->td_proc->p_pid, &logsoftc.sc_sigio); /* signal process only */
return (0);
}
@@ -111,10 +118,14 @@ static int
logclose(struct cdev *dev, int flag, int mode, struct thread *td)
{
- log_open = 0;
+ funsetown(&logsoftc.sc_sigio);
+
+ mtx_lock(&msgbuf_lock);
callout_stop(&logsoftc.sc_callout);
logsoftc.sc_state = 0;
- funsetown(&logsoftc.sc_sigio);
+ log_open = 0;
+ mtx_unlock(&msgbuf_lock);
+
return (0);
}
@@ -124,32 +135,32 @@ logread(struct cdev *dev, struct uio *ui
{
char buf[128];
struct msgbuf *mbp = msgbufp;
- int error = 0, l, s;
+ int error = 0, l;
- s = splhigh();
+ mtx_lock(&msgbuf_lock);
while (msgbuf_getcount(mbp) == 0) {
if (flag & IO_NDELAY) {
- splx(s);
+ mtx_unlock(&msgbuf_lock);
return (EWOULDBLOCK);
}
- logsoftc.sc_state |= LOG_RDWAIT;
- if ((error = tsleep(mbp, LOG_RDPRI | PCATCH, "klog", 0))) {
- splx(s);
+ if ((error = cv_wait_sig(&log_wakeup, &msgbuf_lock)) != 0) {
+ mtx_unlock(&msgbuf_lock);
return (error);
}
}
- splx(s);
- logsoftc.sc_state &= ~LOG_RDWAIT;
while (uio->uio_resid > 0) {
l = imin(sizeof(buf), uio->uio_resid);
l = msgbuf_getbytes(mbp, buf, l);
if (l == 0)
break;
+ mtx_unlock(&msgbuf_lock);
error = uiomove(buf, l, uio);
- if (error)
- break;
+ if (error || uio->uio_resid == 0)
+ return (error);
+ mtx_lock(&msgbuf_lock);
}
+ mtx_unlock(&msgbuf_lock);
return (error);
}
@@ -157,18 +168,16 @@ logread(struct cdev *dev, struct uio *ui
static int
logpoll(struct cdev *dev, int events, struct thread *td)
{
- int s;
int revents = 0;
- s = splhigh();
-
if (events & (POLLIN | POLLRDNORM)) {
+ mtx_lock(&msgbuf_lock);
if (msgbuf_getcount(msgbufp) > 0)
revents |= events & (POLLIN | POLLRDNORM);
else
selrecord(td, &logsoftc.sc_selp);
+ mtx_unlock(&msgbuf_lock);
}
- splx(s);
return (revents);
}
@@ -183,20 +192,16 @@ logtimeout(void *arg)
log_wakeups_per_second = 1;
}
if (msgbuftrigger == 0) {
- callout_reset(&logsoftc.sc_callout,
- hz / log_wakeups_per_second, logtimeout, NULL);
+ callout_schedule(&logsoftc.sc_callout,
+ hz / log_wakeups_per_second);
return;
}
msgbuftrigger = 0;
selwakeuppri(&logsoftc.sc_selp, LOG_RDPRI);
if ((logsoftc.sc_state & LOG_ASYNC) && logsoftc.sc_sigio != NULL)
pgsigio(&logsoftc.sc_sigio, SIGIO, 0);
- if (logsoftc.sc_state & LOG_RDWAIT) {
- wakeup(msgbufp);
- logsoftc.sc_state &= ~LOG_RDWAIT;
- }
- callout_reset(&logsoftc.sc_callout, hz / log_wakeups_per_second,
- logtimeout, NULL);
+ cv_broadcastpri(&log_wakeup, LOG_RDPRI);
+ callout_schedule(&logsoftc.sc_callout, hz / log_wakeups_per_second);
}
/*ARGSUSED*/
@@ -215,10 +220,12 @@ logioctl(struct cdev *dev, u_long com, c
break;
case FIOASYNC:
+ mtx_lock(&msgbuf_lock);
if (*(int *)data)
logsoftc.sc_state |= LOG_ASYNC;
else
logsoftc.sc_state &= ~LOG_ASYNC;
+ mtx_unlock(&msgbuf_lock);
break;
case FIOSETOWN:
@@ -247,6 +254,8 @@ static void
log_drvinit(void *unused)
{
+ cv_init(&log_wakeup, "klog");
+ callout_init_mtx(&logsoftc.sc_callout, &msgbuf_lock, 0);
make_dev(&log_cdevsw, 0, UID_ROOT, GID_WHEEL, 0600, "klog");
}
Modified: head/sys/kern/subr_prf.c
==============================================================================
--- head/sys/kern/subr_prf.c Tue Nov 3 21:06:19 2009 (r198859)
+++ head/sys/kern/subr_prf.c Tue Nov 3 21:06:19 2009 (r198860)
@@ -923,16 +923,24 @@ sysctl_kern_msgbuf(SYSCTL_HANDLER_ARGS)
}
/* Read the whole buffer, one chunk at a time. */
+ mtx_lock(&msgbuf_lock);
msgbuf_peekbytes(msgbufp, NULL, 0, &seq);
- while ((len = msgbuf_peekbytes(msgbufp, buf, sizeof(buf), &seq)) > 0) {
+ for (;;) {
+ len = msgbuf_peekbytes(msgbufp, buf, sizeof(buf), &seq);
+ mtx_unlock(&msgbuf_lock);
+ if (len == 0)
+ return (0);
+
error = sysctl_handle_opaque(oidp, buf, len, req);
if (error)
return (error);
+
+ mtx_lock(&msgbuf_lock);
}
- return (0);
}
-SYSCTL_PROC(_kern, OID_AUTO, msgbuf, CTLTYPE_STRING | CTLFLAG_RD,
+SYSCTL_PROC(_kern, OID_AUTO, msgbuf,
+ CTLTYPE_STRING | CTLFLAG_RD | CTLFLAG_MPSAFE,
NULL, 0, sysctl_kern_msgbuf, "A", "Contents of kernel message buffer");
static int msgbuf_clearflag;
@@ -943,15 +951,18 @@ sysctl_kern_msgbuf_clear(SYSCTL_HANDLER_
int error;
error = sysctl_handle_int(oidp, oidp->oid_arg1, oidp->oid_arg2, req);
if (!error && req->newptr) {
+ mtx_lock(&msgbuf_lock);
msgbuf_clear(msgbufp);
+ mtx_unlock(&msgbuf_lock);
msgbuf_clearflag = 0;
}
return (error);
}
SYSCTL_PROC(_kern, OID_AUTO, msgbuf_clear,
- CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE, &msgbuf_clearflag, 0,
- sysctl_kern_msgbuf_clear, "I", "Clear kernel message buffer");
+ CTLTYPE_INT | CTLFLAG_RW | CTLFLAG_SECURE | CTLFLAG_MPSAFE,
+ &msgbuf_clearflag, 0, sysctl_kern_msgbuf_clear, "I",
+ "Clear kernel message buffer");
#ifdef DDB
Modified: head/sys/sys/msgbuf.h
==============================================================================
--- head/sys/sys/msgbuf.h Tue Nov 3 21:06:19 2009 (r198859)
+++ head/sys/sys/msgbuf.h Tue Nov 3 21:06:19 2009 (r198860)
@@ -54,6 +54,7 @@ struct msgbuf {
#ifdef _KERNEL
extern int msgbuftrigger;
extern struct msgbuf *msgbufp;
+extern struct mtx msgbuf_lock;
void msgbufinit(void *ptr, int size);
void msgbuf_addchar(struct msgbuf *mbp, int c);
From weongyo at FreeBSD.org Tue Nov 3 21:47:08 2009
From: weongyo at FreeBSD.org (Weongyo Jeong)
Date: Tue Nov 3 21:47:19 2009
Subject: svn commit: r198862 - head/sys/dev/usb/wlan
Message-ID: <200911032147.nA3Ll7AA006232@svn.freebsd.org>
Author: weongyo
Date: Tue Nov 3 21:47:07 2009
New Revision: 198862
URL: http://svn.freebsd.org/changeset/base/198862
Log:
fixes a typo that value should be 0 not 10.
Modified:
head/sys/dev/usb/wlan/if_urtw.c
Modified: head/sys/dev/usb/wlan/if_urtw.c
==============================================================================
--- head/sys/dev/usb/wlan/if_urtw.c Tue Nov 3 21:24:37 2009 (r198861)
+++ head/sys/dev/usb/wlan/if_urtw.c Tue Nov 3 21:47:07 2009 (r198862)
@@ -1688,7 +1688,7 @@ urtw_tx_start(struct urtw_softc *sc, str
ieee80211_radiotap_tx(vap, m0);
}
- if ((wh->i_fc[10] & IEEE80211_FC0_TYPE_MASK) == IEEE80211_FC0_TYPE_MGT ||
+ if ((wh->i_fc[0] & IEEE80211_FC0_TYPE_MASK) == IEEE80211_FC0_TYPE_MGT ||
(wh->i_fc[0] & IEEE80211_FC0_TYPE_MASK) == IEEE80211_FC0_TYPE_CTL) {
tp = &vap->iv_txparms[ieee80211_chan2mode(ic->ic_curchan)];
rate = tp->mgmtrate;
From mlaier at FreeBSD.org Tue Nov 3 21:57:01 2009
From: mlaier at FreeBSD.org (Max Laier)
Date: Tue Nov 3 21:57:07 2009
Subject: svn commit: r198863 - stable/8/sys/conf
Message-ID: <200911032157.nA3Lv0Qn006582@svn.freebsd.org>
Author: mlaier
Date: Tue Nov 3 21:57:00 2009
New Revision: 198863
URL: http://svn.freebsd.org/changeset/base/198863
Log:
MFC r197334,r197433:
Extract svn and git version info from git-svn repos.
Modified:
stable/8/sys/conf/newvers.sh
Directory Properties:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/conf/newvers.sh
==============================================================================
--- stable/8/sys/conf/newvers.sh Tue Nov 3 21:47:07 2009 (r198862)
+++ stable/8/sys/conf/newvers.sh Tue Nov 3 21:57:00 2009 (r198863)
@@ -89,28 +89,54 @@ i=`${MAKE:-make} -V KERN_IDENT`
case "$d" in
*/sys/*)
+ SRCDIR=${d##*obj}
+ if [ -n "$MACHINE" ]; then
+ SRCDIR=${SRCDIR##/$MACHINE}
+ fi
+ SRCDIR=${SRCDIR%%/sys/*}
+
for dir in /bin /usr/bin /usr/local/bin; do
- if [ -x "${dir}/svnversion" ]; then
+ if [ -d "${SRCDIR}/sys/.svn" -a -x "${dir}/svnversion" ] ; then
svnversion=${dir}/svnversion
- SRCDIR=${d##*obj}
- if [ -n "$MACHINE" ]; then
- SRCDIR=${SRCDIR##/$MACHINE}
- fi
- SRCDIR=${SRCDIR%%/sys/*}
+ break
+ fi
+ if [ -d "${SRCDIR}/.git" -a -x "${dir}/git" ] ; then
+ git_cmd="${dir}/git --git-dir=${SRCDIR}/.git"
break
fi
done
- if [ -n "$svnversion" -a -d "${SRCDIR}/sys/.svn" ] ; then
+ if [ -n "$svnversion" ] ; then
svn=" r`cd ${SRCDIR}/sys && $svnversion`"
fi
+ if [ -n "$git_cmd" ] ; then
+ git=`$git_cmd rev-parse --verify --short HEAD 2>/dev/null`
+ svn=`$git_cmd svn find-rev $git 2>/dev/null`
+ if [ -n "$svn" ] ; then
+ svn=" r${svn}"
+ git="=${git}"
+ else
+ svn=`$git_cmd log | fgrep 'git-svn-id:' | head -1 | \
+ sed -n 's/^.*@\([0-9][0-9]*\).*$/\1/p'`
+ if [ -n $svn ] ; then
+ svn=" r${svn}"
+ git="+${git}"
+ else
+ git=" ${git}"
+ fi
+ fi
+ if $git_cmd --work-tree=${SRCDIR} diff-index \
+ --name-only HEAD | read dummy; then
+ git="${git}-dirty"
+ fi
+ fi
;;
esac
cat << EOF > vers.c
$COPYRIGHT
-#define SCCSSTR "@(#)${VERSION} #${v}${svn}: ${t}"
-#define VERSTR "${VERSION} #${v}${svn}: ${t}\\n ${u}@${h}:${d}\\n"
+#define SCCSSTR "@(#)${VERSION} #${v}${svn}${git}: ${t}"
+#define VERSTR "${VERSION} #${v}${svn}${git}: ${t}\\n ${u}@${h}:${d}\\n"
#define RELSTR "${RELEASE}"
char sccs[sizeof(SCCSSTR) > 128 ? sizeof(SCCSSTR) : 128] = SCCSSTR;
From rpaulo at FreeBSD.org Tue Nov 3 23:26:32 2009
From: rpaulo at FreeBSD.org (Rui Paulo)
Date: Tue Nov 3 23:26:48 2009
Subject: svn commit: r198864 - stable/8/sys/net80211
Message-ID: <200911032326.nA3NQVZG009193@svn.freebsd.org>
Author: rpaulo
Date: Tue Nov 3 23:26:31 2009
New Revision: 198864
URL: http://svn.freebsd.org/changeset/base/198864
Log:
MFC r198581:
Update the route's sequence number upon receiving a RANN.
Modified:
stable/8/sys/net80211/ieee80211_hwmp.c
Directory Properties:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/net80211/ieee80211_hwmp.c
==============================================================================
--- stable/8/sys/net80211/ieee80211_hwmp.c Tue Nov 3 21:57:00 2009 (r198863)
+++ stable/8/sys/net80211/ieee80211_hwmp.c Tue Nov 3 23:26:31 2009 (r198864)
@@ -1239,15 +1239,18 @@ hwmp_recv_rann(struct ieee80211vap *vap,
return;
}
hr = IEEE80211_MESH_ROUTE_PRIV(rt, struct ieee80211_hwmp_route);
- if (HWMP_SEQ_GT(rann->rann_seq, hr->hr_seq) && rann->rann_ttl > 1 &&
- rann->rann_hopcount < hs->hs_maxhops &&
- (ms->ms_flags & IEEE80211_MESHFLAGS_FWD)) {
- memcpy(&prann, rann, sizeof(prann));
- prann.rann_hopcount += 1;
- prann.rann_ttl -= 1;
- prann.rann_metric += ms->ms_pmetric->mpm_metric(ni);
- hwmp_send_rann(vap->iv_bss, vap->iv_myaddr, broadcastaddr,
- &prann);
+ if (HWMP_SEQ_GT(rann->rann_seq, hr->hr_seq)) {
+ hr->hr_seq = rann->rann_seq;
+ if (rann->rann_ttl > 1 &&
+ rann->rann_hopcount < hs->hs_maxhops &&
+ (ms->ms_flags & IEEE80211_MESHFLAGS_FWD)) {
+ memcpy(&prann, rann, sizeof(prann));
+ prann.rann_hopcount += 1;
+ prann.rann_ttl -= 1;
+ prann.rann_metric += ms->ms_pmetric->mpm_metric(ni);
+ hwmp_send_rann(vap->iv_bss, vap->iv_myaddr,
+ broadcastaddr, &prann);
+ }
}
}
From mav at FreeBSD.org Tue Nov 3 23:26:58 2009
From: mav at FreeBSD.org (Alexander Motin)
Date: Tue Nov 3 23:27:10 2009
Subject: svn commit: r198865 - head/sys/sys
Message-ID: <200911032326.nA3NQwqJ009239@svn.freebsd.org>
Author: mav
Date: Tue Nov 3 23:26:58 2009
New Revision: 198865
URL: http://svn.freebsd.org/changeset/base/198865
Log:
Fix constants.
Modified:
head/sys/sys/ata.h
Modified: head/sys/sys/ata.h
==============================================================================
--- head/sys/sys/ata.h Tue Nov 3 23:26:31 2009 (r198864)
+++ head/sys/sys/ata.h Tue Nov 3 23:26:58 2009 (r198865)
@@ -207,8 +207,8 @@ struct ata_params {
u_int16_t reserved104[2];
/*106*/ u_int16_t pss;
#define ATA_PSS_LSPPS 0x000F
-#define ATA_PSS_LSSABOVE512 0x2000
-#define ATA_PSS_MULTLS 0x4000
+#define ATA_PSS_LSSABOVE512 0x1000
+#define ATA_PSS_MULTLS 0x2000
/*107*/ u_int16_t isd;
/*108*/ u_int16_t wwn[4];
u_int16_t reserved112[5];
From jkim at FreeBSD.org Wed Nov 4 00:58:22 2009
From: jkim at FreeBSD.org (Jung-uk Kim)
Date: Wed Nov 4 00:58:33 2009
Subject: svn commit: r198866 - in head/sys: dev/fb isa
Message-ID: <200911040058.nA40wKZp011756@svn.freebsd.org>
Author: jkim
Date: Wed Nov 4 00:58:20 2009
New Revision: 198866
URL: http://svn.freebsd.org/changeset/base/198866
Log:
Save/restore VGA color palette while suspending and resuming.
Modified:
head/sys/dev/fb/vgareg.h
head/sys/isa/vga_isa.c
Modified: head/sys/dev/fb/vgareg.h
==============================================================================
--- head/sys/dev/fb/vgareg.h Tue Nov 3 23:26:58 2009 (r198865)
+++ head/sys/dev/fb/vgareg.h Wed Nov 4 00:58:20 2009 (r198866)
@@ -70,6 +70,7 @@ struct video_adapter;
typedef struct vga_softc {
struct video_adapter *adp;
void *state_buf;
+ void *pal_buf;
#ifdef FB_INSTALL_CDEV
genfb_softc_t gensc;
#endif
Modified: head/sys/isa/vga_isa.c
==============================================================================
--- head/sys/isa/vga_isa.c Tue Nov 3 23:26:58 2009 (r198865)
+++ head/sys/isa/vga_isa.c Wed Nov 4 00:58:20 2009 (r198866)
@@ -179,17 +179,33 @@ isavga_suspend(device_t dev)
nbytes = vidd_save_state(sc->adp, NULL, 0);
if (nbytes <= 0)
return (0);
- sc->state_buf = malloc(nbytes, M_TEMP, M_NOWAIT | M_ZERO);
- if (sc->state_buf == NULL)
- return (0);
- if (bootverbose)
- device_printf(dev, "saving %d bytes of video state\n", nbytes);
- if (vidd_save_state(sc->adp, sc->state_buf, nbytes) != 0) {
- device_printf(dev, "failed to save state (nbytes=%d)\n",
- nbytes);
- free(sc->state_buf, M_TEMP);
- sc->state_buf = NULL;
+ sc->state_buf = malloc(nbytes, M_TEMP, M_NOWAIT);
+ if (sc->state_buf != NULL) {
+ if (bootverbose)
+ device_printf(dev, "saving %d bytes of video state\n",
+ nbytes);
+ if (vidd_save_state(sc->adp, sc->state_buf, nbytes) != 0) {
+ device_printf(dev, "failed to save state (nbytes=%d)\n",
+ nbytes);
+ free(sc->state_buf, M_TEMP);
+ sc->state_buf = NULL;
+ }
}
+
+ /* Save the color palette across the suspend. */
+ if (sc->pal_buf != NULL)
+ free(sc->pal_buf, M_TEMP);
+ sc->pal_buf = malloc(256 * 3, M_TEMP, M_NOWAIT);
+ if (sc->pal_buf != NULL) {
+ if (bootverbose)
+ device_printf(dev, "saving color palette\n");
+ if (vidd_save_palette(sc->adp, sc->pal_buf) != 0) {
+ device_printf(dev, "failed to save palette\n");
+ free(sc->pal_buf, M_TEMP);
+ sc->pal_buf = NULL;
+ }
+ }
+
return (0);
}
@@ -205,6 +221,12 @@ isavga_resume(device_t dev)
free(sc->state_buf, M_TEMP);
sc->state_buf = NULL;
}
+ if (sc->pal_buf != NULL) {
+ if (vidd_load_palette(sc->adp, sc->pal_buf) != 0)
+ device_printf(dev, "failed to reload palette\n");
+ free(sc->pal_buf, M_TEMP);
+ sc->pal_buf = NULL;
+ }
bus_generic_resume(dev);
return 0;
From jkim at FreeBSD.org Wed Nov 4 01:00:28 2009
From: jkim at FreeBSD.org (Jung-uk Kim)
Date: Wed Nov 4 01:00:41 2009
Subject: svn commit: r198867 - head/sys/dev/fb
Message-ID: <200911040100.nA410SsC011883@svn.freebsd.org>
Author: jkim
Date: Wed Nov 4 01:00:28 2009
New Revision: 198867
URL: http://svn.freebsd.org/changeset/base/198867
Log:
Restore color palette format if we reset video mode.
Modified:
head/sys/dev/fb/vesa.c
Modified: head/sys/dev/fb/vesa.c
==============================================================================
--- head/sys/dev/fb/vesa.c Wed Nov 4 00:58:20 2009 (r198866)
+++ head/sys/dev/fb/vesa.c Wed Nov 4 01:00:28 2009 (r198867)
@@ -1470,6 +1470,8 @@ vesa_load_state(video_adapter_t *adp, vo
(flags & V_INFO_LINEAR) != 0)
mode |= 0x4000;
(void)vesa_bios_set_mode(mode);
+ if ((vesa_adp_info->v_flags & V_DAC8) != 0)
+ (void)vesa_bios_set_dac(8);
(void)(*vidsw[adp->va_index]->set_hw_cursor)(adp, -1, -1);
}
From attilio at FreeBSD.org Wed Nov 4 01:33:00 2009
From: attilio at FreeBSD.org (Attilio Rao)
Date: Wed Nov 4 01:33:06 2009
Subject: svn commit: r198868 - in head/sys: amd64/amd64 i386/i386
Message-ID: <200911040132.nA41WxtQ012750@svn.freebsd.org>
Author: attilio
Date: Wed Nov 4 01:32:59 2009
New Revision: 198868
URL: http://svn.freebsd.org/changeset/base/198868
Log:
Opteron rev E family of processor expose a bug where, in very rare
ocassions, memory barriers semantic is not honoured by the hardware
itself. As a result, some random breakage can happen in uninvestigable
ways (for further explanation see at the content of the commit itself).
As long as just a specific familly is bugged of an entire architecture
is broken, a complete fix-up is impratical without harming to some
extents the other correct cases.
Considering that (and considering the frequency of the bug exposure)
just print out a warning message if the affected machine is identified.
Pointed out by: Samy Al Bahra
Help on wordings by: jeff
MFC: 3 days
Modified:
head/sys/amd64/amd64/identcpu.c
head/sys/i386/i386/identcpu.c
Modified: head/sys/amd64/amd64/identcpu.c
==============================================================================
--- head/sys/amd64/amd64/identcpu.c Wed Nov 4 01:00:28 2009 (r198867)
+++ head/sys/amd64/amd64/identcpu.c Wed Nov 4 01:32:59 2009 (r198868)
@@ -607,6 +607,24 @@ print_AMD_info(void)
printf(", %d lines/tag", (regs[2] >> 8) & 0x0f);
print_AMD_l2_assoc((regs[2] >> 12) & 0x0f);
}
+
+ /*
+ * Opteron Rev E shows a bug as in very rare occasions a read memory
+ * barrier is not performed as expected if it is followed by a
+ * non-atomic read-modify-write instruction.
+ * As long as that bug pops up very rarely (intensive machine usage
+ * on other operating systems generally generates one unexplainable
+ * crash any 2 months) and as long as a model specific fix would be
+ * impratical at this stage, print out a warning string if the broken
+ * model and family are identified.
+ */
+ if (CPUID_TO_FAMILY(cpu_id) == 0xf && CPUID_TO_MODEL(cpu_id) >= 0x20 &&
+ CPUID_TO_MODEL(cpu_id) <= 0x3f) {
+ printf("WARNING: This architecture revision has known SMP "
+ "hardware bugs which may cause random instability\n");
+ printf("WARNING: For details see: "
+ "http://bugzilla.kernel.org/show_bug.cgi?id=11305\n");
+ }
}
static void
Modified: head/sys/i386/i386/identcpu.c
==============================================================================
--- head/sys/i386/i386/identcpu.c Wed Nov 4 01:00:28 2009 (r198867)
+++ head/sys/i386/i386/identcpu.c Wed Nov 4 01:32:59 2009 (r198868)
@@ -1303,6 +1303,24 @@ print_AMD_info(void)
(amd_whcr & 0x0100) ? "Enable" : "Disable");
}
}
+
+ /*
+ * Opteron Rev E shows a bug as in very rare occasions a read memory
+ * barrier is not performed as expected if it is followed by a
+ * non-atomic read-modify-write instruction.
+ * As long as that bug pops up very rarely (intensive machine usage
+ * on other operating systems generally generates one unexplainable
+ * crash any 2 months) and as long as a model specific fix would be
+ * impratical at this stage, print out a warning string if the broken
+ * model and family are identified.
+ */
+ if (CPUID_TO_FAMILY(cpu_id) == 0xf && CPUID_TO_MODEL(cpu_id) >= 0x20 &&
+ CPUID_TO_MODEL(cpu_id) <= 0x3f) {
+ printf("WARNING: This architecture revision has known SMP "
+ "hardware bugs which may cause random instability\n");
+ printf("WARNING: For details see: "
+ "http://bugzilla.kernel.org/show_bug.cgi?id=11305\n");
+ }
}
static void
From thompsa at FreeBSD.org Wed Nov 4 01:50:26 2009
From: thompsa at FreeBSD.org (Andrew Thompson)
Date: Wed Nov 4 01:50:32 2009
Subject: svn commit: r198869 - stable/8/sys/dev/usb
Message-ID: <200911040150.nA41oPZ3013287@svn.freebsd.org>
Author: thompsa
Date: Wed Nov 4 01:50:25 2009
New Revision: 198869
URL: http://svn.freebsd.org/changeset/base/198869
Log:
MFC r198775
Fix a corner case where usbd_transfer_drain() can return too early if the
callback has dropped the mutex, leading to a panic.
Submitted by: HPS
Modified:
stable/8/sys/dev/usb/usb_core.h
stable/8/sys/dev/usb/usb_transfer.c
Directory Properties:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/dev/usb/usb_core.h
==============================================================================
--- stable/8/sys/dev/usb/usb_core.h Wed Nov 4 01:32:59 2009 (r198868)
+++ stable/8/sys/dev/usb/usb_core.h Wed Nov 4 01:50:25 2009 (r198869)
@@ -112,6 +112,7 @@ struct usb_xfer_flags_int {
uint8_t curr_dma_set:1; /* used by USB HC/DC driver */
uint8_t can_cancel_immed:1; /* set if USB transfer can be
* cancelled immediately */
+ uint8_t doing_callback:1; /* set if executing the callback */
};
/*
Modified: stable/8/sys/dev/usb/usb_transfer.c
==============================================================================
--- stable/8/sys/dev/usb/usb_transfer.c Wed Nov 4 01:32:59 2009 (r198868)
+++ stable/8/sys/dev/usb/usb_transfer.c Wed Nov 4 01:50:25 2009 (r198869)
@@ -1797,8 +1797,18 @@ usbd_transfer_drain(struct usb_xfer *xfe
usbd_transfer_stop(xfer);
- while (usbd_transfer_pending(xfer)) {
+ while (usbd_transfer_pending(xfer) ||
+ xfer->flags_int.doing_callback) {
+
+ /*
+ * It is allowed that the callback can drop its
+ * transfer mutex. In that case checking only
+ * "usbd_transfer_pending()" is not enough to tell if
+ * the USB transfer is fully drained. We also need to
+ * check the internal "doing_callback" flag.
+ */
xfer->flags_int.draining = 1;
+
/*
* Wait until the current outstanding USB
* transfer is complete !
@@ -2043,6 +2053,9 @@ usbd_callback_wrapper(struct usb_xfer_qu
/* get next USB transfer in the queue */
info->done_q.curr = NULL;
+ /* set flag in case of drain */
+ xfer->flags_int.doing_callback = 1;
+
USB_BUS_UNLOCK(info->bus);
USB_BUS_LOCK_ASSERT(info->bus, MA_NOTOWNED);
@@ -2095,12 +2108,17 @@ usbd_callback_wrapper(struct usb_xfer_qu
if ((!xfer->flags_int.open) &&
(xfer->flags_int.started) &&
(xfer->usb_state == USB_ST_ERROR)) {
+ /* clear flag in case of drain */
+ xfer->flags_int.doing_callback = 0;
/* try to loop, but not recursivly */
usb_command_wrapper(&info->done_q, xfer);
return;
}
done:
+ /* clear flag in case of drain */
+ xfer->flags_int.doing_callback = 0;
+
/*
* Check if we are draining.
*/
From alc at FreeBSD.org Wed Nov 4 03:12:57 2009
From: alc at FreeBSD.org (Alan Cox)
Date: Wed Nov 4 03:13:09 2009
Subject: svn commit: r198870 - head/sys/vm
Message-ID: <200911040312.nA43CvCu015910@svn.freebsd.org>
Author: alc
Date: Wed Nov 4 03:12:56 2009
New Revision: 198870
URL: http://svn.freebsd.org/changeset/base/198870
Log:
Eliminate an unnecessary #include. (This #include should have been removed
in r188331 when vnode_pager_lock() was eliminated.)
Modified:
head/sys/vm/vm_fault.c
Modified: head/sys/vm/vm_fault.c
==============================================================================
--- head/sys/vm/vm_fault.c Wed Nov 4 01:50:25 2009 (r198869)
+++ head/sys/vm/vm_fault.c Wed Nov 4 03:12:56 2009 (r198870)
@@ -96,7 +96,6 @@ __FBSDID("$FreeBSD$");
#include
#include
#include
-#include
#include
#include /* XXX Temporary for VFS_LOCK_GIANT() */
From benno at FreeBSD.org Wed Nov 4 04:12:56 2009
From: benno at FreeBSD.org (Benno Rice)
Date: Wed Nov 4 04:13:08 2009
Subject: svn commit: r198871 - head/share/man/man3
Message-ID: <200911040412.nA44CuSq017605@svn.freebsd.org>
Author: benno
Date: Wed Nov 4 04:12:56 2009
New Revision: 198871
URL: http://svn.freebsd.org/changeset/base/198871
Log:
Fix typo (noded -> nodes).
Modified:
head/share/man/man3/tree.3
Modified: head/share/man/man3/tree.3
==============================================================================
--- head/share/man/man3/tree.3 Wed Nov 4 03:12:56 2009 (r198870)
+++ head/share/man/man3/tree.3 Wed Nov 4 04:12:56 2009 (r198871)
@@ -384,7 +384,7 @@ macros, but should be used only once.
Finally,
the
.Fa CMP
-argument is the name of a function used to compare tree noded
+argument is the name of a function used to compare tree nodes
with each other.
The function takes two arguments of type
.Vt "struct TYPE *" .
From alc at FreeBSD.org Wed Nov 4 04:41:03 2009
From: alc at FreeBSD.org (Alan Cox)
Date: Wed Nov 4 04:41:14 2009
Subject: svn commit: r198872 - in head/sys/arm: arm at91 mv sa11x0
Message-ID: <200911040441.nA44f3HN018343@svn.freebsd.org>
Author: alc
Date: Wed Nov 4 04:41:03 2009
New Revision: 198872
URL: http://svn.freebsd.org/changeset/base/198872
Log:
Eliminate an unnecessary vm include file.
Modified:
head/sys/arm/arm/machdep.c
head/sys/arm/at91/at91_machdep.c
head/sys/arm/mv/mv_machdep.c
head/sys/arm/sa11x0/assabet_machdep.c
Modified: head/sys/arm/arm/machdep.c
==============================================================================
--- head/sys/arm/arm/machdep.c Wed Nov 4 04:12:56 2009 (r198871)
+++ head/sys/arm/arm/machdep.c Wed Nov 4 04:41:03 2009 (r198872)
@@ -77,7 +77,6 @@ __FBSDID("$FreeBSD$");
#include
#include
#include
-#include
#include
#include
Modified: head/sys/arm/at91/at91_machdep.c
==============================================================================
--- head/sys/arm/at91/at91_machdep.c Wed Nov 4 04:12:56 2009 (r198871)
+++ head/sys/arm/at91/at91_machdep.c Wed Nov 4 04:41:03 2009 (r198872)
@@ -79,7 +79,6 @@ __FBSDID("$FreeBSD$");
#include
#include
#include
-#include
#include
#include
#include
Modified: head/sys/arm/mv/mv_machdep.c
==============================================================================
--- head/sys/arm/mv/mv_machdep.c Wed Nov 4 04:12:56 2009 (r198871)
+++ head/sys/arm/mv/mv_machdep.c Wed Nov 4 04:41:03 2009 (r198872)
@@ -72,7 +72,6 @@ __FBSDID("$FreeBSD$");
#include
#include
#include
-#include
#include
#include
#include
Modified: head/sys/arm/sa11x0/assabet_machdep.c
==============================================================================
--- head/sys/arm/sa11x0/assabet_machdep.c Wed Nov 4 04:12:56 2009 (r198871)
+++ head/sys/arm/sa11x0/assabet_machdep.c Wed Nov 4 04:41:03 2009 (r198872)
@@ -82,7 +82,6 @@ __FBSDID("$FreeBSD$");
#include
#include
#include
-#include
#include
#include
#include
From ed at 80386.nl Wed Nov 4 05:58:14 2009
From: ed at 80386.nl (Ed Schouten)
Date: Wed Nov 4 05:58:25 2009
Subject: svn commit: r198868 - in head/sys: amd64/amd64 i386/i386
In-Reply-To: <200911040132.nA41WxtQ012750@svn.freebsd.org>
References: <200911040132.nA41WxtQ012750@svn.freebsd.org>
Message-ID: <20091104055811.GY1293@hoeg.nl>
Hi Attilio,
* Attilio Rao wrote:
> Opteron rev E family of processor expose a bug where, in very rare
> ocassions, memory barriers semantic is not honoured by the hardware
> itself. As a result, some random breakage can happen in uninvestigable
> ways (for further explanation see at the content of the commit itself).
Ooh. Sounds like an interesting bug.
The bug doesn't manifest itself on UP, right? If so, maybe we should add
some very short instructions to the warning on how to disable SMP.
--
Ed Schouten
WWW: http://80386.nl/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091104/d1db4814/attachment.pgp
From trasz at FreeBSD.org Wed Nov 4 06:47:14 2009
From: trasz at FreeBSD.org (Edward Tomasz Napierala)
Date: Wed Nov 4 06:47:31 2009
Subject: svn commit: r198873 - head/sys/kern
Message-ID: <200911040647.nA46lEUg021790@svn.freebsd.org>
Author: trasz
Date: Wed Nov 4 06:47:14 2009
New Revision: 198873
URL: http://svn.freebsd.org/changeset/base/198873
Log:
While VAPPEND without VWRITE makes sense for VOP_ACCESSX(9) (e.g. to check
for the permission to create subdirectory (ACE4_ADD_SUBDIRECTORY)), it doesn't
really make sense for VOP_ACCESS(9). Also, many VOP_ACCESS(9) implementations
don't expect that. Make sure we don't confuse them.
Modified:
head/sys/kern/vfs_default.c
Modified: head/sys/kern/vfs_default.c
==============================================================================
--- head/sys/kern/vfs_default.c Wed Nov 4 04:41:03 2009 (r198872)
+++ head/sys/kern/vfs_default.c Wed Nov 4 06:47:14 2009 (r198873)
@@ -353,6 +353,14 @@ vop_stdaccessx(struct vop_accessx_args *
if (accmode == 0)
return (0);
+ /*
+ * Many VOP_APPEND implementations don't expect VAPPEND without VWRITE
+ * being set, e.g. they check whether the filesystem is read-only only
+ * when VWRITE is set. Make sure we don't confuse them.
+ */
+ if (accmode & VAPPEND)
+ accmode |= VWRITE;
+
return (VOP_ACCESS(ap->a_vp, accmode, ap->a_cred, ap->a_td));
}
From trasz at FreeBSD.org Wed Nov 4 06:48:34 2009
From: trasz at FreeBSD.org (Edward Tomasz Napierala)
Date: Wed Nov 4 06:48:40 2009
Subject: svn commit: r198874 - head/sys/kern
Message-ID: <200911040648.nA46mYrb021862@svn.freebsd.org>
Author: trasz
Date: Wed Nov 4 06:48:34 2009
New Revision: 198874
URL: http://svn.freebsd.org/changeset/base/198874
Log:
Make sure we don't end up with VAPPEND without VWRITE, if someone calls open(2)
like this: open(..., O_APPEND).
Modified:
head/sys/kern/vfs_vnops.c
Modified: head/sys/kern/vfs_vnops.c
==============================================================================
--- head/sys/kern/vfs_vnops.c Wed Nov 4 06:47:14 2009 (r198873)
+++ head/sys/kern/vfs_vnops.c Wed Nov 4 06:48:34 2009 (r198874)
@@ -213,7 +213,7 @@ restart:
if (fmode & FEXEC)
accmode |= VEXEC;
if (fmode & O_APPEND)
- accmode |= VAPPEND;
+ accmode |= VWRITE | VAPPEND;
#ifdef MAC
error = mac_vnode_check_open(cred, vp, accmode);
if (error)
From trasz at FreeBSD.org Wed Nov 4 07:04:16 2009
From: trasz at FreeBSD.org (Edward Tomasz Napierala)
Date: Wed Nov 4 07:04:27 2009
Subject: svn commit: r198875 - head/sys/kern
Message-ID: <200911040704.nA474FDo022330@svn.freebsd.org>
Author: trasz
Date: Wed Nov 4 07:04:15 2009
New Revision: 198875
URL: http://svn.freebsd.org/changeset/base/198875
Log:
Style fixes.
Modified:
head/sys/kern/vfs_acl.c
Modified: head/sys/kern/vfs_acl.c
==============================================================================
--- head/sys/kern/vfs_acl.c Wed Nov 4 06:48:34 2009 (r198874)
+++ head/sys/kern/vfs_acl.c Wed Nov 4 07:04:15 2009 (r198875)
@@ -213,7 +213,7 @@ vacl_set_acl(struct thread *td, struct v
inkernelacl = acl_alloc(M_WAITOK);
error = acl_copyin(aclp, inkernelacl, type);
- if (error)
+ if (error != 0)
goto out;
error = vn_start_write(vp, &mp, V_WAIT | PCATCH);
if (error != 0)
@@ -233,7 +233,7 @@ out_unlock:
vn_finished_write(mp);
out:
acl_free(inkernelacl);
- return(error);
+ return (error);
}
/*
@@ -276,12 +276,12 @@ vacl_delete(struct thread *td, struct vn
int error;
error = vn_start_write(vp, &mp, V_WAIT | PCATCH);
- if (error)
+ if (error != 0)
return (error);
vn_lock(vp, LK_EXCLUSIVE | LK_RETRY);
#ifdef MAC
error = mac_vnode_check_deleteacl(td->td_ucred, vp, type);
- if (error)
+ if (error != 0)
goto out;
#endif
error = VOP_SETACL(vp, acl_type_unold(type), 0, td->td_ucred, td);
@@ -305,7 +305,7 @@ vacl_aclcheck(struct thread *td, struct
inkernelacl = acl_alloc(M_WAITOK);
error = acl_copyin(aclp, inkernelacl, type);
- if (error)
+ if (error != 0)
goto out;
error = VOP_ACLCHECK(vp, type, inkernelacl, td->td_ucred, td);
out:
@@ -501,7 +501,7 @@ __acl_delete_fd(struct thread *td, struc
int
__acl_aclcheck_file(struct thread *td, struct __acl_aclcheck_file_args *uap)
{
- struct nameidata nd;
+ struct nameidata nd;
int vfslocked, error;
NDINIT(&nd, LOOKUP, MPSAFE|FOLLOW, UIO_USERSPACE, uap->path, td);
@@ -521,7 +521,7 @@ __acl_aclcheck_file(struct thread *td, s
int
__acl_aclcheck_link(struct thread *td, struct __acl_aclcheck_link_args *uap)
{
- struct nameidata nd;
+ struct nameidat nd;
int vfslocked, error;
NDINIT(&nd, LOOKUP, MPSAFE|NOFOLLOW, UIO_USERSPACE, uap->path, td);
From pjd at FreeBSD.org Wed Nov 4 07:04:35 2009
From: pjd at FreeBSD.org (Pawel Jakub Dawidek)
Date: Wed Nov 4 07:04:41 2009
Subject: svn commit: r198874 - head/sys/kern
In-Reply-To: <200911040648.nA46mYrb021862@svn.freebsd.org>
References: <200911040648.nA46mYrb021862@svn.freebsd.org>
Message-ID: <20091104070427.GE2073@garage.freebsd.pl>
On Wed, Nov 04, 2009 at 06:48:34AM +0000, Edward Tomasz Napierala wrote:
> Author: trasz
> Date: Wed Nov 4 06:48:34 2009
> New Revision: 198874
> URL: http://svn.freebsd.org/changeset/base/198874
>
> Log:
> Make sure we don't end up with VAPPEND without VWRITE, if someone calls open(2)
> like this: open(..., O_APPEND).
>
> Modified:
> head/sys/kern/vfs_vnops.c
>
> Modified: head/sys/kern/vfs_vnops.c
> ==============================================================================
> --- head/sys/kern/vfs_vnops.c Wed Nov 4 06:47:14 2009 (r198873)
> +++ head/sys/kern/vfs_vnops.c Wed Nov 4 06:48:34 2009 (r198874)
> @@ -213,7 +213,7 @@ restart:
> if (fmode & FEXEC)
> accmode |= VEXEC;
> if (fmode & O_APPEND)
> - accmode |= VAPPEND;
> + accmode |= VWRITE | VAPPEND;
> #ifdef MAC
> error = mac_vnode_check_open(cred, vp, accmode);
> if (error)
Why? If someone does O_APPEND only we don't want to give him write
access...
--
Pawel Jakub Dawidek http://www.wheel.pl
pjd@FreeBSD.org http://www.FreeBSD.org
FreeBSD committer Am I Evil? Yes, I Am!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091104/6c520118/attachment.pgp
From pjd at FreeBSD.org Wed Nov 4 07:07:50 2009
From: pjd at FreeBSD.org (Pawel Jakub Dawidek)
Date: Wed Nov 4 07:07:56 2009
Subject: svn commit: r198873 - head/sys/kern
In-Reply-To: <200911040647.nA46lEUg021790@svn.freebsd.org>
References: <200911040647.nA46lEUg021790@svn.freebsd.org>
Message-ID: <20091104070741.GF2073@garage.freebsd.pl>
On Wed, Nov 04, 2009 at 06:47:14AM +0000, Edward Tomasz Napierala wrote:
> Author: trasz
> Date: Wed Nov 4 06:47:14 2009
> New Revision: 198873
> URL: http://svn.freebsd.org/changeset/base/198873
>
> Log:
> While VAPPEND without VWRITE makes sense for VOP_ACCESSX(9) (e.g. to check
> for the permission to create subdirectory (ACE4_ADD_SUBDIRECTORY)), it doesn't
> really make sense for VOP_ACCESS(9). Also, many VOP_ACCESS(9) implementations
> don't expect that. Make sure we don't confuse them.
>
> Modified:
> head/sys/kern/vfs_default.c
>
> Modified: head/sys/kern/vfs_default.c
> ==============================================================================
> --- head/sys/kern/vfs_default.c Wed Nov 4 04:41:03 2009 (r198872)
> +++ head/sys/kern/vfs_default.c Wed Nov 4 06:47:14 2009 (r198873)
> @@ -353,6 +353,14 @@ vop_stdaccessx(struct vop_accessx_args *
> if (accmode == 0)
> return (0);
>
> + /*
> + * Many VOP_APPEND implementations don't expect VAPPEND without VWRITE
> + * being set, e.g. they check whether the filesystem is read-only only
> + * when VWRITE is set. Make sure we don't confuse them.
But O_APPEND alone is legal and doesn't provide write access. This is
fine for file systems to only check for read-only in VWRITE case.
If file system you're talking about is ZFS it was simply a bug in ZFS.
> + */
> + if (accmode & VAPPEND)
> + accmode |= VWRITE;
> return (VOP_ACCESS(ap->a_vp, accmode, ap->a_cred, ap->a_td));
--
Pawel Jakub Dawidek http://www.wheel.pl
pjd@FreeBSD.org http://www.FreeBSD.org
FreeBSD committer Am I Evil? Yes, I Am!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091104/741e15fc/attachment.pgp
From trasz at FreeBSD.org Wed Nov 4 07:14:18 2009
From: trasz at FreeBSD.org (Edward Tomasz Napierala)
Date: Wed Nov 4 07:14:25 2009
Subject: svn commit: r198876 - head/sys/kern
Message-ID: <200911040714.nA47EGDc022619@svn.freebsd.org>
Author: trasz
Date: Wed Nov 4 07:14:16 2009
New Revision: 198876
URL: http://svn.freebsd.org/changeset/base/198876
Log:
Revert r198874, pending further discussion.
Modified:
head/sys/kern/vfs_vnops.c
Modified: head/sys/kern/vfs_vnops.c
==============================================================================
--- head/sys/kern/vfs_vnops.c Wed Nov 4 07:04:15 2009 (r198875)
+++ head/sys/kern/vfs_vnops.c Wed Nov 4 07:14:16 2009 (r198876)
@@ -213,7 +213,7 @@ restart:
if (fmode & FEXEC)
accmode |= VEXEC;
if (fmode & O_APPEND)
- accmode |= VWRITE | VAPPEND;
+ accmode |= VAPPEND;
#ifdef MAC
error = mac_vnode_check_open(cred, vp, accmode);
if (error)
From trasz at FreeBSD.org Wed Nov 4 08:25:59 2009
From: trasz at FreeBSD.org (Edward Tomasz Napierala)
Date: Wed Nov 4 08:26:13 2009
Subject: svn commit: r198877 - head/sys/kern
Message-ID: <200911040825.nA48PwuI024360@svn.freebsd.org>
Author: trasz
Date: Wed Nov 4 08:25:58 2009
New Revision: 198877
URL: http://svn.freebsd.org/changeset/base/198877
Log:
Fix build.
Submitted by: Andrius Mork?nas
Modified:
head/sys/kern/vfs_acl.c
Modified: head/sys/kern/vfs_acl.c
==============================================================================
--- head/sys/kern/vfs_acl.c Wed Nov 4 07:14:16 2009 (r198876)
+++ head/sys/kern/vfs_acl.c Wed Nov 4 08:25:58 2009 (r198877)
@@ -521,7 +521,7 @@ __acl_aclcheck_file(struct thread *td, s
int
__acl_aclcheck_link(struct thread *td, struct __acl_aclcheck_link_args *uap)
{
- struct nameidat nd;
+ struct nameidata nd;
int vfslocked, error;
NDINIT(&nd, LOOKUP, MPSAFE|NOFOLLOW, UIO_USERSPACE, uap->path, td);
From edwin at FreeBSD.org Wed Nov 4 10:46:56 2009
From: edwin at FreeBSD.org (Edwin Groothuis)
Date: Wed Nov 4 10:47:08 2009
Subject: svn commit: r198878 - stable/8/share/zoneinfo
Message-ID: <200911041046.nA4Akt03028773@svn.freebsd.org>
Author: edwin
Date: Wed Nov 4 10:46:55 2009
New Revision: 198878
URL: http://svn.freebsd.org/changeset/base/198878
Log:
MFC of r198825: tzdata2009q
- New region: Asia/Novokuznetsk
- Kemerovo oblast' (Kemerovo region) in Russia will change current
time zone on 29 March 2010
- Add historical data for Hongkong 1941 - 1980
- Syria will go to winter time in the last weekend of October 2009.
Modified:
stable/8/share/zoneinfo/asia
stable/8/share/zoneinfo/europe
stable/8/share/zoneinfo/zone.tab
Directory Properties:
stable/8/share/zoneinfo/ (props changed)
Modified: stable/8/share/zoneinfo/asia
==============================================================================
--- stable/8/share/zoneinfo/asia Wed Nov 4 08:25:58 2009 (r198877)
+++ stable/8/share/zoneinfo/asia Wed Nov 4 10:46:55 2009 (r198878)
@@ -1,5 +1,4 @@
-#
-# @(#)asia 8.42
+# @(#)asia 8.44
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
@@ -369,14 +368,84 @@ Zone Asia/Kashgar 5:03:56 - LMT 1928 # o
5:00 - KAST 1980 May
8:00 PRC C%sT
+
+# From Lee Yiu Chung (2009-10-24):
+# I found there are some mistakes for the historial DST rule for Hong
+# Kong. Accoring to the DST record from Hong Kong Observatory (actually,
+# it is not [an] observatory, but the official meteorological agency of HK,
+# and also serves as the official timing agency), there are some missing
+# and incorrect rules. Although the exact switch over time is missing, I
+# think 3:30 is correct. The official DST record for Hong Kong can be
+# obtained from
+#
+# http://www.hko.gov.hk/gts/time/Summertime.htm
+# .
+
+# From Arthur David Olson (2009-10-28):
+# Here are the dates given at
+#
+# http://www.hko.gov.hk/gts/time/Summertime.htm
+#
+# as of 2009-10-28:
+# Year Period
+# 1941 1 Apr to 30 Sep
+# 1942 Whole year
+# 1943 Whole year
+# 1944 Whole year
+# 1945 Whole year
+# 1946 20 Apr to 1 Dec
+# 1947 13 Apr to 30 Dec
+# 1948 2 May to 31 Oct
+# 1949 3 Apr to 30 Oct
+# 1950 2 Apr to 29 Oct
+# 1951 1 Apr to 28 Oct
+# 1952 6 Apr to 25 Oct
+# 1953 5 Apr to 1 Nov
+# 1954 21 Mar to 31 Oct
+# 1955 20 Mar to 6 Nov
+# 1956 18 Mar to 4 Nov
+# 1957 24 Mar to 3 Nov
+# 1958 23 Mar to 2 Nov
+# 1959 22 Mar to 1 Nov
+# 1960 20 Mar to 6 Nov
+# 1961 19 Mar to 5 Nov
+# 1962 18 Mar to 4 Nov
+# 1963 24 Mar to 3 Nov
+# 1964 22 Mar to 1 Nov
+# 1965 18 Apr to 17 Oct
+# 1966 17 Apr to 16 Oct
+# 1967 16 Apr to 22 Oct
+# 1968 21 Apr to 20 Oct
+# 1969 20 Apr to 19 Oct
+# 1970 19 Apr to 18 Oct
+# 1971 18 Apr to 17 Oct
+# 1972 16 Apr to 22 Oct
+# 1973 22 Apr to 21 Oct
+# 1973/74 30 Dec 73 to 20 Oct 74
+# 1975 20 Apr to 19 Oct
+# 1976 18 Apr to 17 Oct
+# 1977 Nil
+# 1978 Nil
+# 1979 13 May to 21 Oct
+# 1980 to Now Nil
+# The page does not give start or end times of day.
+# The page does not give a start date for 1942.
+# The page does not givw an end date for 1945.
+# The Japanese occupation of Hong Kong began on 1941-12-25.
+# The Japanese surrender of Hong Kong was signed 1945-09-15.
+# For lack of anything better, use start of those days as the transition times.
+
# Hong Kong (Xianggang)
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
+Rule HK 1941 only - Apr 1 3:30 1:00 S
+Rule HK 1941 only - Sep 30 3:30 0 -
Rule HK 1946 only - Apr 20 3:30 1:00 S
Rule HK 1946 only - Dec 1 3:30 0 -
Rule HK 1947 only - Apr 13 3:30 1:00 S
Rule HK 1947 only - Dec 30 3:30 0 -
Rule HK 1948 only - May 2 3:30 1:00 S
-Rule HK 1948 1952 - Oct lastSun 3:30 0 -
+Rule HK 1948 1951 - Oct lastSun 3:30 0 -
+Rule HK 1952 only - Oct 25 3:30 0 -
Rule HK 1949 1953 - Apr Sun>=1 3:30 1:00 S
Rule HK 1953 only - Nov 1 3:30 0 -
Rule HK 1954 1964 - Mar Sun>=18 3:30 1:00 S
@@ -384,13 +453,15 @@ Rule HK 1954 only - Oct 31 3:30 0 -
Rule HK 1955 1964 - Nov Sun>=1 3:30 0 -
Rule HK 1965 1977 - Apr Sun>=16 3:30 1:00 S
Rule HK 1965 1977 - Oct Sun>=16 3:30 0 -
-Rule HK 1979 1980 - May Sun>=8 3:30 1:00 S
-Rule HK 1979 1980 - Oct Sun>=16 3:30 0 -
+Rule HK 1973 only - Dec 30 3:30 1:00 S
+Rule HK 1979 only - May Sun>=8 3:30 1:00 S
+Rule HK 1979 only - Oct Sun>=16 3:30 0 -
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Hong_Kong 7:36:36 - LMT 1904 Oct 30
+ 8:00 HK HK%sT 1941 Dec 25
+ 9:00 - JST 1945 Sep 15
8:00 HK HK%sT
-
###############################################################################
# Taiwan
@@ -2236,9 +2307,23 @@ Rule Syria 2007 only - Nov Fri>=1 0:00
# http://www.timeanddate.com/news/time/syria-dst-starts-march-27-2009.html
#
+# From Steffen Thorsen (2009-10-27):
+# The Syrian Arab News Network on 2009-09-29 reported that Syria will
+# revert back to winter (standard) time on midnight between Thursday
+# 2009-10-29 and Friday 2009-10-30:
+#
+# http://www.sana.sy/ara/2/2009/09/29/247012.htm (Arabic)
+#
+
+# From Arthur David Olson (2009-10-28):
+# We'll see if future DST switching times turn out to be end of the last
+# Thursday of the month or the start of the last Friday of the month or
+# something else. For now, use the start of the last Friday.
+
Rule Syria 2008 only - Apr Fri>=1 0:00 1:00 S
-Rule Syria 2008 max - Nov 1 0:00 0 -
+Rule Syria 2008 only - Nov 1 0:00 0 -
Rule Syria 2009 max - Mar lastFri 0:00 1:00 S
+Rule Syria 2009 max - Oct lastFri 0:00 0 -
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Damascus 2:25:12 - LMT 1920 # Dimashq
Modified: stable/8/share/zoneinfo/europe
==============================================================================
--- stable/8/share/zoneinfo/europe Wed Nov 4 08:25:58 2009 (r198877)
+++ stable/8/share/zoneinfo/europe Wed Nov 4 10:46:55 2009 (r198878)
@@ -1,5 +1,5 @@
#
-# @(#)europe 8.22
+# @(#)europe 8.24
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
@@ -2072,9 +2072,43 @@ Zone Asia/Novosibirsk 5:31:40 - LMT 191
6:00 Russia NOV%sT 1992 Jan 19 2:00s
7:00 Russia NOV%sT 1993 May 23 # say Shanks & P.
6:00 Russia NOV%sT
+
+# From Alexander Krivenyshev (2009-10-13):
+# Kemerovo oblast' (Kemerovo region) in Russia will change current time zone on
+# March 28, 2010:
+# from current Russia Zone 6 - Krasnoyarsk Time Zone (KRA) UTC +0700
+# to Russia Zone 5 - Novosibirsk Time Zone (NOV) UTC +0600
+#
+# This is according to Government of Russia decree # 740, on September
+# 14, 2009 "Application in the territory of the Kemerovo region the Fifth
+# time zone." ("Russia Zone 5" or old "USSR Zone 5" is GMT +0600)
+#
+# Russian Government web site (Russian language)
+#
+# http://www.government.ru/content/governmentactivity/rfgovernmentdecisions/archive/2009/09/14/991633.htm
+#
+# or Russian-English translation by WorldTimeZone.com with reference
+# map to local region and new Russia Time Zone map after March 28, 2010
+#
+# http://www.worldtimezone.com/dst_news/dst_news_russia03.html
+#
+#
+# Thus, when Russia will switch to DST on the night of March 28, 2010
+# Kemerovo region (Kemerovo oblast') will not change the clock.
+#
+# As a result, Kemerovo oblast' will be in the same time zone as
+# Novosibirsk, Omsk, Tomsk, Barnaul and Altai Republic.
+
+Zone Asia/Novokuznetsk 5:48:48 - NMT 1920 Jan 6
+ 6:00 - KRAT 1930 Jun 21 # Krasnoyarsk Time
+ 7:00 Russia KRA%sT 1991 Mar 31 2:00s
+ 6:00 Russia KRA%sT 1992 Jan 19 2:00s
+ 7:00 Russia KRA%sT 2010 Mar 28 2:00s
+ 6:00 Russia NOV%sT # Novosibirsk/Novokuznetsk Time
+
#
# From Oscar van Vlijmen (2001-08-25): [This region consists of]
-# Kemerovskaya oblast', Krasnoyarskij kraj,
+# Krasnoyarskij kraj,
# Tajmyrskij (Dolgano-Nenetskij) avtonomnyj okrug,
# Respublika Tuva, Respublika Khakasiya, Evenkijskij avtonomnyj okrug.
Zone Asia/Krasnoyarsk 6:11:20 - LMT 1920 Jan 6
Modified: stable/8/share/zoneinfo/zone.tab
==============================================================================
--- stable/8/share/zoneinfo/zone.tab Wed Nov 4 08:25:58 2009 (r198877)
+++ stable/8/share/zoneinfo/zone.tab Wed Nov 4 10:46:55 2009 (r198878)
@@ -1,5 +1,5 @@
#
-# @(#)zone.tab 8.28
+# @(#)zone.tab 8.29
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
#
@@ -330,6 +330,7 @@ RU +5312+05009 Europe/Samara Moscow+01 -
RU +5651+06036 Asia/Yekaterinburg Moscow+02 - Urals
RU +5500+07324 Asia/Omsk Moscow+03 - west Siberia
RU +5502+08255 Asia/Novosibirsk Moscow+03 - Novosibirsk
+RU +5345+08707 Asia/Novokuznetsk Moscow+03 - Novokuznetsk
RU +5601+09250 Asia/Krasnoyarsk Moscow+04 - Yenisei River
RU +5216+10420 Asia/Irkutsk Moscow+05 - Lake Baikal
RU +6200+12940 Asia/Yakutsk Moscow+06 - Lena River
From edwin at FreeBSD.org Wed Nov 4 10:47:05 2009
From: edwin at FreeBSD.org (Edwin Groothuis)
Date: Wed Nov 4 10:47:25 2009
Subject: svn commit: r198879 - stable/6/share/zoneinfo
Message-ID: <200911041047.nA4Al2Pe028816@svn.freebsd.org>
Author: edwin
Date: Wed Nov 4 10:47:02 2009
New Revision: 198879
URL: http://svn.freebsd.org/changeset/base/198879
Log:
MFC of r198825: tzdata2009q
- New region: Asia/Novokuznetsk
- Kemerovo oblast' (Kemerovo region) in Russia will change current
time zone on 29 March 2010
- Add historical data for Hongkong 1941 - 1980
- Syria will go to winter time in the last weekend of October 2009.
Modified:
stable/6/share/zoneinfo/asia
stable/6/share/zoneinfo/europe
stable/6/share/zoneinfo/zone.tab
Directory Properties:
stable/6/share/zoneinfo/ (props changed)
Modified: stable/6/share/zoneinfo/asia
==============================================================================
--- stable/6/share/zoneinfo/asia Wed Nov 4 10:46:55 2009 (r198878)
+++ stable/6/share/zoneinfo/asia Wed Nov 4 10:47:02 2009 (r198879)
@@ -1,5 +1,4 @@
-#
-# @(#)asia 8.42
+# @(#)asia 8.44
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
@@ -369,14 +368,84 @@ Zone Asia/Kashgar 5:03:56 - LMT 1928 # o
5:00 - KAST 1980 May
8:00 PRC C%sT
+
+# From Lee Yiu Chung (2009-10-24):
+# I found there are some mistakes for the historial DST rule for Hong
+# Kong. Accoring to the DST record from Hong Kong Observatory (actually,
+# it is not [an] observatory, but the official meteorological agency of HK,
+# and also serves as the official timing agency), there are some missing
+# and incorrect rules. Although the exact switch over time is missing, I
+# think 3:30 is correct. The official DST record for Hong Kong can be
+# obtained from
+#
+# http://www.hko.gov.hk/gts/time/Summertime.htm
+# .
+
+# From Arthur David Olson (2009-10-28):
+# Here are the dates given at
+#
+# http://www.hko.gov.hk/gts/time/Summertime.htm
+#
+# as of 2009-10-28:
+# Year Period
+# 1941 1 Apr to 30 Sep
+# 1942 Whole year
+# 1943 Whole year
+# 1944 Whole year
+# 1945 Whole year
+# 1946 20 Apr to 1 Dec
+# 1947 13 Apr to 30 Dec
+# 1948 2 May to 31 Oct
+# 1949 3 Apr to 30 Oct
+# 1950 2 Apr to 29 Oct
+# 1951 1 Apr to 28 Oct
+# 1952 6 Apr to 25 Oct
+# 1953 5 Apr to 1 Nov
+# 1954 21 Mar to 31 Oct
+# 1955 20 Mar to 6 Nov
+# 1956 18 Mar to 4 Nov
+# 1957 24 Mar to 3 Nov
+# 1958 23 Mar to 2 Nov
+# 1959 22 Mar to 1 Nov
+# 1960 20 Mar to 6 Nov
+# 1961 19 Mar to 5 Nov
+# 1962 18 Mar to 4 Nov
+# 1963 24 Mar to 3 Nov
+# 1964 22 Mar to 1 Nov
+# 1965 18 Apr to 17 Oct
+# 1966 17 Apr to 16 Oct
+# 1967 16 Apr to 22 Oct
+# 1968 21 Apr to 20 Oct
+# 1969 20 Apr to 19 Oct
+# 1970 19 Apr to 18 Oct
+# 1971 18 Apr to 17 Oct
+# 1972 16 Apr to 22 Oct
+# 1973 22 Apr to 21 Oct
+# 1973/74 30 Dec 73 to 20 Oct 74
+# 1975 20 Apr to 19 Oct
+# 1976 18 Apr to 17 Oct
+# 1977 Nil
+# 1978 Nil
+# 1979 13 May to 21 Oct
+# 1980 to Now Nil
+# The page does not give start or end times of day.
+# The page does not give a start date for 1942.
+# The page does not givw an end date for 1945.
+# The Japanese occupation of Hong Kong began on 1941-12-25.
+# The Japanese surrender of Hong Kong was signed 1945-09-15.
+# For lack of anything better, use start of those days as the transition times.
+
# Hong Kong (Xianggang)
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
+Rule HK 1941 only - Apr 1 3:30 1:00 S
+Rule HK 1941 only - Sep 30 3:30 0 -
Rule HK 1946 only - Apr 20 3:30 1:00 S
Rule HK 1946 only - Dec 1 3:30 0 -
Rule HK 1947 only - Apr 13 3:30 1:00 S
Rule HK 1947 only - Dec 30 3:30 0 -
Rule HK 1948 only - May 2 3:30 1:00 S
-Rule HK 1948 1952 - Oct lastSun 3:30 0 -
+Rule HK 1948 1951 - Oct lastSun 3:30 0 -
+Rule HK 1952 only - Oct 25 3:30 0 -
Rule HK 1949 1953 - Apr Sun>=1 3:30 1:00 S
Rule HK 1953 only - Nov 1 3:30 0 -
Rule HK 1954 1964 - Mar Sun>=18 3:30 1:00 S
@@ -384,13 +453,15 @@ Rule HK 1954 only - Oct 31 3:30 0 -
Rule HK 1955 1964 - Nov Sun>=1 3:30 0 -
Rule HK 1965 1977 - Apr Sun>=16 3:30 1:00 S
Rule HK 1965 1977 - Oct Sun>=16 3:30 0 -
-Rule HK 1979 1980 - May Sun>=8 3:30 1:00 S
-Rule HK 1979 1980 - Oct Sun>=16 3:30 0 -
+Rule HK 1973 only - Dec 30 3:30 1:00 S
+Rule HK 1979 only - May Sun>=8 3:30 1:00 S
+Rule HK 1979 only - Oct Sun>=16 3:30 0 -
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Hong_Kong 7:36:36 - LMT 1904 Oct 30
+ 8:00 HK HK%sT 1941 Dec 25
+ 9:00 - JST 1945 Sep 15
8:00 HK HK%sT
-
###############################################################################
# Taiwan
@@ -2236,9 +2307,23 @@ Rule Syria 2007 only - Nov Fri>=1 0:00
# http://www.timeanddate.com/news/time/syria-dst-starts-march-27-2009.html
#
+# From Steffen Thorsen (2009-10-27):
+# The Syrian Arab News Network on 2009-09-29 reported that Syria will
+# revert back to winter (standard) time on midnight between Thursday
+# 2009-10-29 and Friday 2009-10-30:
+#
+# http://www.sana.sy/ara/2/2009/09/29/247012.htm (Arabic)
+#
+
+# From Arthur David Olson (2009-10-28):
+# We'll see if future DST switching times turn out to be end of the last
+# Thursday of the month or the start of the last Friday of the month or
+# something else. For now, use the start of the last Friday.
+
Rule Syria 2008 only - Apr Fri>=1 0:00 1:00 S
-Rule Syria 2008 max - Nov 1 0:00 0 -
+Rule Syria 2008 only - Nov 1 0:00 0 -
Rule Syria 2009 max - Mar lastFri 0:00 1:00 S
+Rule Syria 2009 max - Oct lastFri 0:00 0 -
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Damascus 2:25:12 - LMT 1920 # Dimashq
Modified: stable/6/share/zoneinfo/europe
==============================================================================
--- stable/6/share/zoneinfo/europe Wed Nov 4 10:46:55 2009 (r198878)
+++ stable/6/share/zoneinfo/europe Wed Nov 4 10:47:02 2009 (r198879)
@@ -1,5 +1,5 @@
#
-# @(#)europe 8.22
+# @(#)europe 8.24
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
@@ -2072,9 +2072,43 @@ Zone Asia/Novosibirsk 5:31:40 - LMT 191
6:00 Russia NOV%sT 1992 Jan 19 2:00s
7:00 Russia NOV%sT 1993 May 23 # say Shanks & P.
6:00 Russia NOV%sT
+
+# From Alexander Krivenyshev (2009-10-13):
+# Kemerovo oblast' (Kemerovo region) in Russia will change current time zone on
+# March 28, 2010:
+# from current Russia Zone 6 - Krasnoyarsk Time Zone (KRA) UTC +0700
+# to Russia Zone 5 - Novosibirsk Time Zone (NOV) UTC +0600
+#
+# This is according to Government of Russia decree # 740, on September
+# 14, 2009 "Application in the territory of the Kemerovo region the Fifth
+# time zone." ("Russia Zone 5" or old "USSR Zone 5" is GMT +0600)
+#
+# Russian Government web site (Russian language)
+#
+# http://www.government.ru/content/governmentactivity/rfgovernmentdecisions/archive/2009/09/14/991633.htm
+#
+# or Russian-English translation by WorldTimeZone.com with reference
+# map to local region and new Russia Time Zone map after March 28, 2010
+#
+# http://www.worldtimezone.com/dst_news/dst_news_russia03.html
+#
+#
+# Thus, when Russia will switch to DST on the night of March 28, 2010
+# Kemerovo region (Kemerovo oblast') will not change the clock.
+#
+# As a result, Kemerovo oblast' will be in the same time zone as
+# Novosibirsk, Omsk, Tomsk, Barnaul and Altai Republic.
+
+Zone Asia/Novokuznetsk 5:48:48 - NMT 1920 Jan 6
+ 6:00 - KRAT 1930 Jun 21 # Krasnoyarsk Time
+ 7:00 Russia KRA%sT 1991 Mar 31 2:00s
+ 6:00 Russia KRA%sT 1992 Jan 19 2:00s
+ 7:00 Russia KRA%sT 2010 Mar 28 2:00s
+ 6:00 Russia NOV%sT # Novosibirsk/Novokuznetsk Time
+
#
# From Oscar van Vlijmen (2001-08-25): [This region consists of]
-# Kemerovskaya oblast', Krasnoyarskij kraj,
+# Krasnoyarskij kraj,
# Tajmyrskij (Dolgano-Nenetskij) avtonomnyj okrug,
# Respublika Tuva, Respublika Khakasiya, Evenkijskij avtonomnyj okrug.
Zone Asia/Krasnoyarsk 6:11:20 - LMT 1920 Jan 6
Modified: stable/6/share/zoneinfo/zone.tab
==============================================================================
--- stable/6/share/zoneinfo/zone.tab Wed Nov 4 10:46:55 2009 (r198878)
+++ stable/6/share/zoneinfo/zone.tab Wed Nov 4 10:47:02 2009 (r198879)
@@ -1,5 +1,5 @@
#
-# @(#)zone.tab 8.28
+# @(#)zone.tab 8.29
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
#
@@ -330,6 +330,7 @@ RU +5312+05009 Europe/Samara Moscow+01 -
RU +5651+06036 Asia/Yekaterinburg Moscow+02 - Urals
RU +5500+07324 Asia/Omsk Moscow+03 - west Siberia
RU +5502+08255 Asia/Novosibirsk Moscow+03 - Novosibirsk
+RU +5345+08707 Asia/Novokuznetsk Moscow+03 - Novokuznetsk
RU +5601+09250 Asia/Krasnoyarsk Moscow+04 - Yenisei River
RU +5216+10420 Asia/Irkutsk Moscow+05 - Lake Baikal
RU +6200+12940 Asia/Yakutsk Moscow+06 - Lena River
From edwin at FreeBSD.org Wed Nov 4 10:47:09 2009
From: edwin at FreeBSD.org (Edwin Groothuis)
Date: Wed Nov 4 10:47:48 2009
Subject: svn commit: r198880 - stable/7/share/zoneinfo
Message-ID: <200911041047.nA4Al91C028857@svn.freebsd.org>
Author: edwin
Date: Wed Nov 4 10:47:09 2009
New Revision: 198880
URL: http://svn.freebsd.org/changeset/base/198880
Log:
MFC of r198825: tzdata2009q
- New region: Asia/Novokuznetsk
- Kemerovo oblast' (Kemerovo region) in Russia will change current
time zone on 29 March 2010
- Add historical data for Hongkong 1941 - 1980
- Syria will go to winter time in the last weekend of October 2009.
Modified:
stable/7/share/zoneinfo/asia
stable/7/share/zoneinfo/europe
stable/7/share/zoneinfo/zone.tab
Directory Properties:
stable/7/share/zoneinfo/ (props changed)
Modified: stable/7/share/zoneinfo/asia
==============================================================================
--- stable/7/share/zoneinfo/asia Wed Nov 4 10:47:02 2009 (r198879)
+++ stable/7/share/zoneinfo/asia Wed Nov 4 10:47:09 2009 (r198880)
@@ -1,5 +1,4 @@
-#
-# @(#)asia 8.42
+# @(#)asia 8.44
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
@@ -369,14 +368,84 @@ Zone Asia/Kashgar 5:03:56 - LMT 1928 # o
5:00 - KAST 1980 May
8:00 PRC C%sT
+
+# From Lee Yiu Chung (2009-10-24):
+# I found there are some mistakes for the historial DST rule for Hong
+# Kong. Accoring to the DST record from Hong Kong Observatory (actually,
+# it is not [an] observatory, but the official meteorological agency of HK,
+# and also serves as the official timing agency), there are some missing
+# and incorrect rules. Although the exact switch over time is missing, I
+# think 3:30 is correct. The official DST record for Hong Kong can be
+# obtained from
+#
+# http://www.hko.gov.hk/gts/time/Summertime.htm
+# .
+
+# From Arthur David Olson (2009-10-28):
+# Here are the dates given at
+#
+# http://www.hko.gov.hk/gts/time/Summertime.htm
+#
+# as of 2009-10-28:
+# Year Period
+# 1941 1 Apr to 30 Sep
+# 1942 Whole year
+# 1943 Whole year
+# 1944 Whole year
+# 1945 Whole year
+# 1946 20 Apr to 1 Dec
+# 1947 13 Apr to 30 Dec
+# 1948 2 May to 31 Oct
+# 1949 3 Apr to 30 Oct
+# 1950 2 Apr to 29 Oct
+# 1951 1 Apr to 28 Oct
+# 1952 6 Apr to 25 Oct
+# 1953 5 Apr to 1 Nov
+# 1954 21 Mar to 31 Oct
+# 1955 20 Mar to 6 Nov
+# 1956 18 Mar to 4 Nov
+# 1957 24 Mar to 3 Nov
+# 1958 23 Mar to 2 Nov
+# 1959 22 Mar to 1 Nov
+# 1960 20 Mar to 6 Nov
+# 1961 19 Mar to 5 Nov
+# 1962 18 Mar to 4 Nov
+# 1963 24 Mar to 3 Nov
+# 1964 22 Mar to 1 Nov
+# 1965 18 Apr to 17 Oct
+# 1966 17 Apr to 16 Oct
+# 1967 16 Apr to 22 Oct
+# 1968 21 Apr to 20 Oct
+# 1969 20 Apr to 19 Oct
+# 1970 19 Apr to 18 Oct
+# 1971 18 Apr to 17 Oct
+# 1972 16 Apr to 22 Oct
+# 1973 22 Apr to 21 Oct
+# 1973/74 30 Dec 73 to 20 Oct 74
+# 1975 20 Apr to 19 Oct
+# 1976 18 Apr to 17 Oct
+# 1977 Nil
+# 1978 Nil
+# 1979 13 May to 21 Oct
+# 1980 to Now Nil
+# The page does not give start or end times of day.
+# The page does not give a start date for 1942.
+# The page does not givw an end date for 1945.
+# The Japanese occupation of Hong Kong began on 1941-12-25.
+# The Japanese surrender of Hong Kong was signed 1945-09-15.
+# For lack of anything better, use start of those days as the transition times.
+
# Hong Kong (Xianggang)
# Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S
+Rule HK 1941 only - Apr 1 3:30 1:00 S
+Rule HK 1941 only - Sep 30 3:30 0 -
Rule HK 1946 only - Apr 20 3:30 1:00 S
Rule HK 1946 only - Dec 1 3:30 0 -
Rule HK 1947 only - Apr 13 3:30 1:00 S
Rule HK 1947 only - Dec 30 3:30 0 -
Rule HK 1948 only - May 2 3:30 1:00 S
-Rule HK 1948 1952 - Oct lastSun 3:30 0 -
+Rule HK 1948 1951 - Oct lastSun 3:30 0 -
+Rule HK 1952 only - Oct 25 3:30 0 -
Rule HK 1949 1953 - Apr Sun>=1 3:30 1:00 S
Rule HK 1953 only - Nov 1 3:30 0 -
Rule HK 1954 1964 - Mar Sun>=18 3:30 1:00 S
@@ -384,13 +453,15 @@ Rule HK 1954 only - Oct 31 3:30 0 -
Rule HK 1955 1964 - Nov Sun>=1 3:30 0 -
Rule HK 1965 1977 - Apr Sun>=16 3:30 1:00 S
Rule HK 1965 1977 - Oct Sun>=16 3:30 0 -
-Rule HK 1979 1980 - May Sun>=8 3:30 1:00 S
-Rule HK 1979 1980 - Oct Sun>=16 3:30 0 -
+Rule HK 1973 only - Dec 30 3:30 1:00 S
+Rule HK 1979 only - May Sun>=8 3:30 1:00 S
+Rule HK 1979 only - Oct Sun>=16 3:30 0 -
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Hong_Kong 7:36:36 - LMT 1904 Oct 30
+ 8:00 HK HK%sT 1941 Dec 25
+ 9:00 - JST 1945 Sep 15
8:00 HK HK%sT
-
###############################################################################
# Taiwan
@@ -2236,9 +2307,23 @@ Rule Syria 2007 only - Nov Fri>=1 0:00
# http://www.timeanddate.com/news/time/syria-dst-starts-march-27-2009.html
#
+# From Steffen Thorsen (2009-10-27):
+# The Syrian Arab News Network on 2009-09-29 reported that Syria will
+# revert back to winter (standard) time on midnight between Thursday
+# 2009-10-29 and Friday 2009-10-30:
+#
+# http://www.sana.sy/ara/2/2009/09/29/247012.htm (Arabic)
+#
+
+# From Arthur David Olson (2009-10-28):
+# We'll see if future DST switching times turn out to be end of the last
+# Thursday of the month or the start of the last Friday of the month or
+# something else. For now, use the start of the last Friday.
+
Rule Syria 2008 only - Apr Fri>=1 0:00 1:00 S
-Rule Syria 2008 max - Nov 1 0:00 0 -
+Rule Syria 2008 only - Nov 1 0:00 0 -
Rule Syria 2009 max - Mar lastFri 0:00 1:00 S
+Rule Syria 2009 max - Oct lastFri 0:00 0 -
# Zone NAME GMTOFF RULES FORMAT [UNTIL]
Zone Asia/Damascus 2:25:12 - LMT 1920 # Dimashq
Modified: stable/7/share/zoneinfo/europe
==============================================================================
--- stable/7/share/zoneinfo/europe Wed Nov 4 10:47:02 2009 (r198879)
+++ stable/7/share/zoneinfo/europe Wed Nov 4 10:47:09 2009 (r198880)
@@ -1,5 +1,5 @@
#
-# @(#)europe 8.22
+# @(#)europe 8.24
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
@@ -2072,9 +2072,43 @@ Zone Asia/Novosibirsk 5:31:40 - LMT 191
6:00 Russia NOV%sT 1992 Jan 19 2:00s
7:00 Russia NOV%sT 1993 May 23 # say Shanks & P.
6:00 Russia NOV%sT
+
+# From Alexander Krivenyshev (2009-10-13):
+# Kemerovo oblast' (Kemerovo region) in Russia will change current time zone on
+# March 28, 2010:
+# from current Russia Zone 6 - Krasnoyarsk Time Zone (KRA) UTC +0700
+# to Russia Zone 5 - Novosibirsk Time Zone (NOV) UTC +0600
+#
+# This is according to Government of Russia decree # 740, on September
+# 14, 2009 "Application in the territory of the Kemerovo region the Fifth
+# time zone." ("Russia Zone 5" or old "USSR Zone 5" is GMT +0600)
+#
+# Russian Government web site (Russian language)
+#
+# http://www.government.ru/content/governmentactivity/rfgovernmentdecisions/archive/2009/09/14/991633.htm
+#
+# or Russian-English translation by WorldTimeZone.com with reference
+# map to local region and new Russia Time Zone map after March 28, 2010
+#
+# http://www.worldtimezone.com/dst_news/dst_news_russia03.html
+#
+#
+# Thus, when Russia will switch to DST on the night of March 28, 2010
+# Kemerovo region (Kemerovo oblast') will not change the clock.
+#
+# As a result, Kemerovo oblast' will be in the same time zone as
+# Novosibirsk, Omsk, Tomsk, Barnaul and Altai Republic.
+
+Zone Asia/Novokuznetsk 5:48:48 - NMT 1920 Jan 6
+ 6:00 - KRAT 1930 Jun 21 # Krasnoyarsk Time
+ 7:00 Russia KRA%sT 1991 Mar 31 2:00s
+ 6:00 Russia KRA%sT 1992 Jan 19 2:00s
+ 7:00 Russia KRA%sT 2010 Mar 28 2:00s
+ 6:00 Russia NOV%sT # Novosibirsk/Novokuznetsk Time
+
#
# From Oscar van Vlijmen (2001-08-25): [This region consists of]
-# Kemerovskaya oblast', Krasnoyarskij kraj,
+# Krasnoyarskij kraj,
# Tajmyrskij (Dolgano-Nenetskij) avtonomnyj okrug,
# Respublika Tuva, Respublika Khakasiya, Evenkijskij avtonomnyj okrug.
Zone Asia/Krasnoyarsk 6:11:20 - LMT 1920 Jan 6
Modified: stable/7/share/zoneinfo/zone.tab
==============================================================================
--- stable/7/share/zoneinfo/zone.tab Wed Nov 4 10:47:02 2009 (r198879)
+++ stable/7/share/zoneinfo/zone.tab Wed Nov 4 10:47:09 2009 (r198880)
@@ -1,5 +1,5 @@
#
-# @(#)zone.tab 8.28
+# @(#)zone.tab 8.29
# This file is in the public domain, so clarified as of
# 2009-05-17 by Arthur David Olson.
#
@@ -330,6 +330,7 @@ RU +5312+05009 Europe/Samara Moscow+01 -
RU +5651+06036 Asia/Yekaterinburg Moscow+02 - Urals
RU +5500+07324 Asia/Omsk Moscow+03 - west Siberia
RU +5502+08255 Asia/Novosibirsk Moscow+03 - Novosibirsk
+RU +5345+08707 Asia/Novokuznetsk Moscow+03 - Novokuznetsk
RU +5601+09250 Asia/Krasnoyarsk Moscow+04 - Yenisei River
RU +5216+10420 Asia/Irkutsk Moscow+05 - Lake Baikal
RU +6200+12940 Asia/Yakutsk Moscow+06 - Lena River
From brueffer at FreeBSD.org Wed Nov 4 12:35:35 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Wed Nov 4 12:35:47 2009
Subject: svn commit: r198881 - stable/8/sys/dev/amr
Message-ID: <200911041235.nA4CZZOV031577@svn.freebsd.org>
Author: brueffer
Date: Wed Nov 4 12:35:35 2009
New Revision: 198881
URL: http://svn.freebsd.org/changeset/base/198881
Log:
MFC: r198546
Remove spurious `)`
Modified:
stable/8/sys/dev/amr/amr.c
Directory Properties:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/dev/amr/amr.c
==============================================================================
--- stable/8/sys/dev/amr/amr.c Wed Nov 4 10:47:09 2009 (r198880)
+++ stable/8/sys/dev/amr/amr.c Wed Nov 4 12:35:35 2009 (r198881)
@@ -225,7 +225,7 @@ amr_attach(struct amr_softc *sc)
}
#ifdef AMR_BOARD_INIT
- if ((AMR_IS_QUARTZ(sc) ? amr_quartz_init(sc) : amr_std_init(sc))))
+ if ((AMR_IS_QUARTZ(sc) ? amr_quartz_init(sc) : amr_std_init(sc)))
return(ENXIO);
#endif
From brueffer at FreeBSD.org Wed Nov 4 12:38:21 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Wed Nov 4 12:38:28 2009
Subject: svn commit: r198882 - stable/7/sys/dev/amr
Message-ID: <200911041238.nA4CcLNP031665@svn.freebsd.org>
Author: brueffer
Date: Wed Nov 4 12:38:21 2009
New Revision: 198882
URL: http://svn.freebsd.org/changeset/base/198882
Log:
MFC: r198546
Remove spurious `)`
Modified:
stable/7/sys/dev/amr/amr.c
Directory Properties:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
Modified: stable/7/sys/dev/amr/amr.c
==============================================================================
--- stable/7/sys/dev/amr/amr.c Wed Nov 4 12:35:35 2009 (r198881)
+++ stable/7/sys/dev/amr/amr.c Wed Nov 4 12:38:21 2009 (r198882)
@@ -231,7 +231,7 @@ amr_attach(struct amr_softc *sc)
}
#ifdef AMR_BOARD_INIT
- if ((AMR_IS_QUARTZ(sc) ? amr_quartz_init(sc) : amr_std_init(sc))))
+ if ((AMR_IS_QUARTZ(sc) ? amr_quartz_init(sc) : amr_std_init(sc)))
return(ENXIO);
#endif
From brueffer at FreeBSD.org Wed Nov 4 12:43:33 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Wed Nov 4 12:43:40 2009
Subject: svn commit: r198883 - stable/6/sys/dev/amr
Message-ID: <200911041243.nA4ChWQi031804@svn.freebsd.org>
Author: brueffer
Date: Wed Nov 4 12:43:31 2009
New Revision: 198883
URL: http://svn.freebsd.org/changeset/base/198883
Log:
MFC: r198546
Remove spurious `)`
Modified:
stable/6/sys/dev/amr/amr.c
Directory Properties:
stable/6/sys/ (props changed)
stable/6/sys/conf/ (props changed)
stable/6/sys/contrib/pf/ (props changed)
stable/6/sys/dev/cxgb/ (props changed)
Modified: stable/6/sys/dev/amr/amr.c
==============================================================================
--- stable/6/sys/dev/amr/amr.c Wed Nov 4 12:38:21 2009 (r198882)
+++ stable/6/sys/dev/amr/amr.c Wed Nov 4 12:43:31 2009 (r198883)
@@ -229,7 +229,7 @@ amr_attach(struct amr_softc *sc)
}
#ifdef AMR_BOARD_INIT
- if ((AMR_IS_QUARTZ(sc) ? amr_quartz_init(sc) : amr_std_init(sc))))
+ if ((AMR_IS_QUARTZ(sc) ? amr_quartz_init(sc) : amr_std_init(sc)))
return(ENXIO);
#endif
From attilio at freebsd.org Wed Nov 4 12:49:43 2009
From: attilio at freebsd.org (Attilio Rao)
Date: Wed Nov 4 12:50:20 2009
Subject: svn commit: r198868 - in head/sys: amd64/amd64 i386/i386
In-Reply-To: <20091104055811.GY1293@hoeg.nl>
References: <200911040132.nA41WxtQ012750@svn.freebsd.org>
<20091104055811.GY1293@hoeg.nl>
Message-ID: <3bbf2fe10911040449j5938ca7eqca5829ceced66f48@mail.gmail.com>
2009/11/4 Ed Schouten :
> Hi Attilio,
>
> * Attilio Rao wrote:
>> Opteron rev E family of processor expose a bug where, in very rare
>> ocassions, memory barriers semantic is not honoured by the hardware
>> itself. As a result, some random breakage can happen in uninvestigable
>> ways (for further explanation see at the content of the commit itself).
>
> Ooh. Sounds like an interesting bug.
>
> The bug doesn't manifest itself on UP, right? If so, maybe we should add
> some very short instructions to the warning on how to disable SMP.
Due to the semantic of the bug, I think that it can manifest itself on
UP and a memory barrier failing on UP means that PREEMPTION can blow
up. Considering this I wouldn't suggest anything different between the
UP vs SMP case.
Attilio
--
Peace can only be achieved by understanding - A. Einstein
From brueffer at FreeBSD.org Wed Nov 4 13:06:09 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Wed Nov 4 13:06:15 2009
Subject: svn commit: r198884 - stable/8/sys/boot/common
Message-ID: <200911041306.nA4D698O032335@svn.freebsd.org>
Author: brueffer
Date: Wed Nov 4 13:06:09 2009
New Revision: 198884
URL: http://svn.freebsd.org/changeset/base/198884
Log:
MFC: r198537
Close a file descriptor leak in an error case.
Modified:
stable/8/sys/boot/common/commands.c
Directory Properties:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/boot/common/commands.c
==============================================================================
--- stable/8/sys/boot/common/commands.c Wed Nov 4 12:43:31 2009 (r198883)
+++ stable/8/sys/boot/common/commands.c Wed Nov 4 13:06:09 2009 (r198884)
@@ -150,6 +150,7 @@ command_help(int argc, char *argv[])
break;
default:
command_errmsg = "usage is 'help []";
+ close(hfd);
return(CMD_ERROR);
}
From brueffer at FreeBSD.org Wed Nov 4 13:08:57 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Wed Nov 4 13:09:08 2009
Subject: svn commit: r198885 - stable/7/sys/boot/common
Message-ID: <200911041308.nA4D8v4B032430@svn.freebsd.org>
Author: brueffer
Date: Wed Nov 4 13:08:57 2009
New Revision: 198885
URL: http://svn.freebsd.org/changeset/base/198885
Log:
MFC: r198537
Close a file descriptor leak in an error case.
Modified:
stable/7/sys/boot/common/commands.c
Directory Properties:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
Modified: stable/7/sys/boot/common/commands.c
==============================================================================
--- stable/7/sys/boot/common/commands.c Wed Nov 4 13:06:09 2009 (r198884)
+++ stable/7/sys/boot/common/commands.c Wed Nov 4 13:08:57 2009 (r198885)
@@ -150,6 +150,7 @@ command_help(int argc, char *argv[])
break;
default:
command_errmsg = "usage is 'help []";
+ close(hfd);
return(CMD_ERROR);
}
From brueffer at FreeBSD.org Wed Nov 4 13:30:32 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Wed Nov 4 13:30:39 2009
Subject: svn commit: r198886 - stable/8/sys/netinet/libalias
Message-ID: <200911041330.nA4DUW3e032910@svn.freebsd.org>
Author: brueffer
Date: Wed Nov 4 13:30:32 2009
New Revision: 198886
URL: http://svn.freebsd.org/changeset/base/198886
Log:
MFC: r198539
Close a stream file descriptor leak.
Modified:
stable/8/sys/netinet/libalias/alias.c
Directory Properties:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/cddl/contrib/opensolaris/ (props changed)
stable/8/sys/contrib/dev/acpica/ (props changed)
stable/8/sys/contrib/pf/ (props changed)
stable/8/sys/dev/xen/xenpci/ (props changed)
Modified: stable/8/sys/netinet/libalias/alias.c
==============================================================================
--- stable/8/sys/netinet/libalias/alias.c Wed Nov 4 13:08:57 2009 (r198885)
+++ stable/8/sys/netinet/libalias/alias.c Wed Nov 4 13:30:32 2009 (r198886)
@@ -1669,6 +1669,7 @@ LibAliasRefreshModules(void)
LibAliasLoadModule(buf);
}
}
+ fclose(fd);
return (0);
}
From brueffer at FreeBSD.org Wed Nov 4 13:32:26 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Wed Nov 4 13:32:32 2009
Subject: svn commit: r198887 - stable/7/sys/netinet/libalias
Message-ID: <200911041332.nA4DWPHK032988@svn.freebsd.org>
Author: brueffer
Date: Wed Nov 4 13:32:25 2009
New Revision: 198887
URL: http://svn.freebsd.org/changeset/base/198887
Log:
MFC: 198539
Close a stream file descriptor leak.
Modified:
stable/7/sys/netinet/libalias/alias.c
Directory Properties:
stable/7/sys/ (props changed)
stable/7/sys/contrib/pf/ (props changed)
Modified: stable/7/sys/netinet/libalias/alias.c
==============================================================================
--- stable/7/sys/netinet/libalias/alias.c Wed Nov 4 13:30:32 2009 (r198886)
+++ stable/7/sys/netinet/libalias/alias.c Wed Nov 4 13:32:25 2009 (r198887)
@@ -1580,6 +1580,7 @@ LibAliasRefreshModules(void)
LibAliasLoadModule(buf);
}
}
+ fclose(fd);
return (0);
}
From brueffer at FreeBSD.org Wed Nov 4 13:40:04 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Wed Nov 4 13:40:16 2009
Subject: svn commit: r198888 - stable/8/lib/libstand
Message-ID: <200911041340.nA4De4Mr033189@svn.freebsd.org>
Author: brueffer
Date: Wed Nov 4 13:40:04 2009
New Revision: 198888
URL: http://svn.freebsd.org/changeset/base/198888
Log:
MFC: r198542
Initialize f_rabuf in the raw device case. A subsequent close()
later on would try to free it, leading to a crash.
Modified:
stable/8/lib/libstand/open.c
Directory Properties:
stable/8/lib/libstand/ (props changed)
Modified: stable/8/lib/libstand/open.c
==============================================================================
--- stable/8/lib/libstand/open.c Wed Nov 4 13:32:25 2009 (r198887)
+++ stable/8/lib/libstand/open.c Wed Nov 4 13:40:04 2009 (r198888)
@@ -113,6 +113,7 @@ open(const char *fname, int mode)
/* see if we opened a raw device; otherwise, 'file' is the file name. */
if (file == (char *)0 || *file == '\0') {
f->f_flags |= F_RAW;
+ f->f_rabuf = NULL;
return (fd);
}
From brueffer at FreeBSD.org Wed Nov 4 13:40:51 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Wed Nov 4 13:40:57 2009
Subject: svn commit: r198889 - stable/7/lib/libstand
Message-ID: <200911041340.nA4Depix033252@svn.freebsd.org>
Author: brueffer
Date: Wed Nov 4 13:40:50 2009
New Revision: 198889
URL: http://svn.freebsd.org/changeset/base/198889
Log:
MFC: r198542
Initialize f_rabuf in the raw device case. A subsequent close()
later on would try to free it, leading to a crash.
Modified:
stable/7/lib/libstand/open.c
Directory Properties:
stable/7/lib/libstand/ (props changed)
Modified: stable/7/lib/libstand/open.c
==============================================================================
--- stable/7/lib/libstand/open.c Wed Nov 4 13:40:04 2009 (r198888)
+++ stable/7/lib/libstand/open.c Wed Nov 4 13:40:50 2009 (r198889)
@@ -113,6 +113,7 @@ open(const char *fname, int mode)
/* see if we opened a raw device; otherwise, 'file' is the file name. */
if (file == (char *)0 || *file == '\0') {
f->f_flags |= F_RAW;
+ f->f_rabuf = NULL;
return (fd);
}
From brueffer at FreeBSD.org Wed Nov 4 13:41:43 2009
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Wed Nov 4 13:42:00 2009
Subject: svn commit: r198890 - stable/6/lib/libstand
Message-ID: <200911041341.nA4DfhNq033320@svn.freebsd.org>
Author: brueffer
Date: Wed Nov 4 13:41:43 2009
New Revision: 198890
URL: http://svn.freebsd.org/changeset/base/198890
Log:
MFC: 198542
Initialize f_rabuf in the raw device case. A subsequent close()
later on would try to free it, leading to a crash.
Modified:
stable/6/lib/libstand/open.c
Directory Properties:
stable/6/lib/libstand/ (props changed)
Modified: stable/6/lib/libstand/open.c
==============================================================================
--- stable/6/lib/libstand/open.c Wed Nov 4 13:40:50 2009 (r198889)
+++ stable/6/lib/libstand/open.c Wed Nov 4 13:41:43 2009 (r198890)
@@ -117,6 +117,7 @@ open(const char *fname, int mode)
/* see if we opened a raw device; otherwise, 'file' is the file name. */
if (file == (char *)0 || *file == '\0') {
f->f_flags |= F_RAW;
+ f->f_rabuf = NULL;
return (fd);
}
From jkoshy at FreeBSD.org Wed Nov 4 14:19:24 2009
From: jkoshy at FreeBSD.org (Joseph Koshy)
Date: Wed Nov 4 14:19:30 2009
Subject: svn commit: r198891 - svnadmin/conf
Message-ID: <200911041419.nA4EJO2P034160@svn.freebsd.org>
Author: jkoshy
Date: Wed Nov 4 14:19:23 2009
New Revision: 198891
URL: http://svn.freebsd.org/changeset/base/198891
Log:
Fabien Thomas (fabient@) is free to fly solo henceforth.
Modified:
svnadmin/conf/mentors
Modified: svnadmin/conf/mentors
==============================================================================
--- svnadmin/conf/mentors Wed Nov 4 13:41:43 2009 (r198890)
+++ svnadmin/conf/mentors Wed Nov 4 14:19:23 2009 (r198891)
@@ -13,7 +13,6 @@
cbzimmer sam
dchagin kib
eri mlaier Co-mentor: thompsa
-fabient jkoshy
ivoras gnn
jh trasz Co-mentor: rwatson
jinmei gnn
From kostikbel at gmail.com Wed Nov 4 14:43:21 2009
From: kostikbel at gmail.com (Kostik Belousov)
Date: Wed Nov 4 14:43:28 2009
Subject: svn commit: r198868 - in head/sys: amd64/amd64 i386/i386
In-Reply-To: <3bbf2fe10911040449j5938ca7eqca5829ceced66f48@mail.gmail.com>
References: <200911040132.nA41WxtQ012750@svn.freebsd.org>
<20091104055811.GY1293@hoeg.nl>
<3bbf2fe10911040449j5938ca7eqca5829ceced66f48@mail.gmail.com>
Message-ID: <20091104144315.GH2331@deviant.kiev.zoral.com.ua>
On Wed, Nov 04, 2009 at 01:49:41PM +0100, Attilio Rao wrote:
> 2009/11/4 Ed Schouten :
> > Hi Attilio,
> >
> > * Attilio Rao wrote:
> >> Opteron rev E family of processor expose a bug where, in very rare
> >> ocassions, memory barriers semantic is not honoured by the hardware
> >> itself. As a result, some random breakage can happen in uninvestigable
> >> ways (for further explanation see at the content of the commit itself).
> >
> > Ooh. Sounds like an interesting bug.
> >
> > The bug doesn't manifest itself on UP, right? If so, maybe we should add
> > some very short instructions to the warning on how to disable SMP.
>
> Due to the semantic of the bug, I think that it can manifest itself on
> UP and a memory barrier failing on UP means that PREEMPTION can blow
> up. Considering this I wouldn't suggest anything different between the
> UP vs SMP case.
CPU is always self-consistent, isn't it ?
Also, I very much dislike idea of making our kernel a collection of
references to the man pages and URLs, esp. when URL point to the
resource not controlled by the project.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20091104/c85a4b99/attachment.pgp
From rdivacky at FreeBSD.org Wed Nov 4 14:58:59 2009
From: rdivacky at FreeBSD.org (Roman Divacky)
Date: Wed Nov 4 14:59:09 2009
Subject: svn commit: r198892 - in vendor/llvm/dist: . autoconf cmake
cmake/modules docs docs/CommandGuide docs/tutorial
examples/BrainF include/llvm include/llvm-c
include/llvm-c/Transforms include/llvm/ADT...
Message-ID: <200911041458.nA4Eww0E035188@svn.freebsd.org>
Author: rdivacky
Date: Wed Nov 4 14:58:56 2009
New Revision: 198892
URL: http://svn.freebsd.org/changeset/base/198892
Log:
Update LLVM to r86025.
Added:
vendor/llvm/dist/include/llvm/ADT/StringSwitch.h
vendor/llvm/dist/include/llvm/Analysis/MemoryBuiltins.h
vendor/llvm/dist/include/llvm/CodeGen/ProcessImplicitDefs.h
vendor/llvm/dist/include/llvm/CodeGen/SlotIndexes.h
vendor/llvm/dist/include/llvm/System/AIXDataTypesFix.h
vendor/llvm/dist/include/llvm/System/DataTypes.h.cmake
vendor/llvm/dist/include/llvm/System/DataTypes.h.in
vendor/llvm/dist/lib/Analysis/MemoryBuiltins.cpp
vendor/llvm/dist/lib/CodeGen/AggressiveAntiDepBreaker.cpp
vendor/llvm/dist/lib/CodeGen/AggressiveAntiDepBreaker.h
vendor/llvm/dist/lib/CodeGen/AntiDepBreaker.h
vendor/llvm/dist/lib/CodeGen/CriticalAntiDepBreaker.cpp
vendor/llvm/dist/lib/CodeGen/CriticalAntiDepBreaker.h
vendor/llvm/dist/lib/CodeGen/ProcessImplicitDefs.cpp
vendor/llvm/dist/lib/CodeGen/SlotIndexes.cpp
vendor/llvm/dist/lib/Target/ARM/NEONMoveFix.cpp
vendor/llvm/dist/lib/Transforms/Scalar/ABCD.cpp
vendor/llvm/dist/lib/Transforms/Scalar/GEPSplitter.cpp
vendor/llvm/dist/lib/Transforms/Scalar/LoopUnrollPass.cpp
vendor/llvm/dist/lib/Transforms/Scalar/SCCVN.cpp
vendor/llvm/dist/lib/Transforms/Utils/LoopUnroll.cpp
vendor/llvm/dist/test/Analysis/BasicAA/phi-and-select.ll
vendor/llvm/dist/test/CodeGen/ARM/2009-10-02-NEONSubregsBug.ll
vendor/llvm/dist/test/CodeGen/ARM/2009-10-27-double-align.ll
vendor/llvm/dist/test/CodeGen/ARM/2009-10-30.ll
vendor/llvm/dist/test/CodeGen/ARM/2009-11-01-NeonMoves.ll
vendor/llvm/dist/test/CodeGen/ARM/2009-11-02-NegativeLane.ll
vendor/llvm/dist/test/CodeGen/ARM/fpconsts.ll
vendor/llvm/dist/test/CodeGen/Thumb2/2009-11-01-CopyReg2RegBug.ll
vendor/llvm/dist/test/CodeGen/Thumb2/cross-rc-coalescing-1.ll
vendor/llvm/dist/test/CodeGen/Thumb2/cross-rc-coalescing-2.ll
vendor/llvm/dist/test/CodeGen/Thumb2/ldr-str-imm12.ll
vendor/llvm/dist/test/CodeGen/Thumb2/machine-licm.ll
vendor/llvm/dist/test/CodeGen/Thumb2/thumb2-cbnz.ll
vendor/llvm/dist/test/CodeGen/X86/2009-10-25-RewriterBug.ll
vendor/llvm/dist/test/CodeGen/X86/2009-11-04-SubregCoalescingBug.ll
vendor/llvm/dist/test/CodeGen/X86/constant-pool-sharing.ll
vendor/llvm/dist/test/CodeGen/X86/large-gep-scale.ll
vendor/llvm/dist/test/CodeGen/X86/negative-stride-fptosi-user.ll
vendor/llvm/dist/test/CodeGen/X86/palignr-2.ll
vendor/llvm/dist/test/CodeGen/X86/x86-64-jumps.ll
vendor/llvm/dist/test/DebugInfo/2009-11-03-InsertExtractValue.ll
vendor/llvm/dist/test/Feature/terminators.ll
vendor/llvm/dist/test/FrontendC++/2009-10-27-crash.cpp
vendor/llvm/dist/test/FrontendC++/integration-O2.cpp
vendor/llvm/dist/test/LLVMC/OptionPreprocessor.td
vendor/llvm/dist/test/Transforms/DeadStoreElimination/lifetime-simple.ll
vendor/llvm/dist/test/Transforms/GVN/invariant-simple.ll
vendor/llvm/dist/test/Transforms/GVN/lifetime-simple.ll
vendor/llvm/dist/test/Transforms/GlobalOpt/heap-sra-3.ll
vendor/llvm/dist/test/Transforms/GlobalOpt/heap-sra-4.ll
vendor/llvm/dist/test/Transforms/LoopDeletion/multiple-exit-conditions.ll
vendor/llvm/dist/test/Transforms/SCCP/crash.ll
vendor/llvm/dist/test/Transforms/SimplifyCFG/duplicate-phis.ll
Deleted:
vendor/llvm/dist/lib/Analysis/MallocHelper.cpp
vendor/llvm/dist/lib/ExecutionEngine/JIT/MacOSJITEventListener.cpp
vendor/llvm/dist/lib/Target/PIC16/MCSectionPIC16.h
vendor/llvm/dist/lib/Transforms/IPO/RaiseAllocations.cpp
vendor/llvm/dist/lib/Transforms/Scalar/CodeGenLICM.cpp
vendor/llvm/dist/lib/Transforms/Utils/UnrollLoop.cpp
Modified:
vendor/llvm/dist/CMakeLists.txt
vendor/llvm/dist/Makefile
vendor/llvm/dist/Makefile.config.in
vendor/llvm/dist/Makefile.rules
vendor/llvm/dist/autoconf/configure.ac
vendor/llvm/dist/cmake/config-ix.cmake
vendor/llvm/dist/cmake/modules/LLVMLibDeps.cmake
vendor/llvm/dist/cmake/modules/LLVMProcessSources.cmake
vendor/llvm/dist/configure
vendor/llvm/dist/docs/BitCodeFormat.html
vendor/llvm/dist/docs/CommandGuide/lit.pod
vendor/llvm/dist/docs/CompilerDriver.html
vendor/llvm/dist/docs/GettingStarted.html
vendor/llvm/dist/docs/LangRef.html
vendor/llvm/dist/docs/Passes.html
vendor/llvm/dist/docs/ReleaseNotes.html
vendor/llvm/dist/docs/TableGenFundamentals.html
vendor/llvm/dist/docs/tutorial/LangImpl4.html
vendor/llvm/dist/docs/tutorial/OCamlLangImpl4.html
vendor/llvm/dist/examples/BrainF/BrainF.cpp
vendor/llvm/dist/include/llvm-c/Core.h
vendor/llvm/dist/include/llvm-c/Transforms/IPO.h
vendor/llvm/dist/include/llvm/ADT/DenseMap.h
vendor/llvm/dist/include/llvm/ADT/EquivalenceClasses.h
vendor/llvm/dist/include/llvm/ADT/FoldingSet.h
vendor/llvm/dist/include/llvm/ADT/ImmutableList.h
vendor/llvm/dist/include/llvm/ADT/ImmutableSet.h
vendor/llvm/dist/include/llvm/ADT/SmallPtrSet.h
vendor/llvm/dist/include/llvm/ADT/SparseBitVector.h
vendor/llvm/dist/include/llvm/ADT/StringExtras.h
vendor/llvm/dist/include/llvm/ADT/Twine.h
vendor/llvm/dist/include/llvm/ADT/ValueMap.h
vendor/llvm/dist/include/llvm/Analysis/AliasSetTracker.h
vendor/llvm/dist/include/llvm/Analysis/DebugInfo.h
vendor/llvm/dist/include/llvm/Analysis/Dominators.h
vendor/llvm/dist/include/llvm/Analysis/LoopInfo.h
vendor/llvm/dist/include/llvm/Analysis/ScalarEvolution.h
vendor/llvm/dist/include/llvm/Analysis/ValueTracking.h
vendor/llvm/dist/include/llvm/BasicBlock.h
vendor/llvm/dist/include/llvm/Bitcode/BitCodes.h
vendor/llvm/dist/include/llvm/Bitcode/Deserialize.h
vendor/llvm/dist/include/llvm/Bitcode/LLVMBitCodes.h
vendor/llvm/dist/include/llvm/CodeGen/AsmPrinter.h
vendor/llvm/dist/include/llvm/CodeGen/BinaryObject.h
vendor/llvm/dist/include/llvm/CodeGen/ELFRelocation.h
vendor/llvm/dist/include/llvm/CodeGen/JITCodeEmitter.h
vendor/llvm/dist/include/llvm/CodeGen/LatencyPriorityQueue.h
vendor/llvm/dist/include/llvm/CodeGen/LiveInterval.h
vendor/llvm/dist/include/llvm/CodeGen/LiveIntervalAnalysis.h
vendor/llvm/dist/include/llvm/CodeGen/LiveStackAnalysis.h
vendor/llvm/dist/include/llvm/CodeGen/MachineBasicBlock.h
vendor/llvm/dist/include/llvm/CodeGen/MachineCodeEmitter.h
vendor/llvm/dist/include/llvm/CodeGen/MachineFrameInfo.h
vendor/llvm/dist/include/llvm/CodeGen/MachineInstrBuilder.h
vendor/llvm/dist/include/llvm/CodeGen/MachineModuleInfo.h
vendor/llvm/dist/include/llvm/CodeGen/MachineOperand.h
vendor/llvm/dist/include/llvm/CodeGen/MachineRelocation.h
vendor/llvm/dist/include/llvm/CodeGen/PseudoSourceValue.h
vendor/llvm/dist/include/llvm/CodeGen/ScheduleDAG.h
vendor/llvm/dist/include/llvm/CodeGen/SelectionDAG.h
vendor/llvm/dist/include/llvm/CodeGen/SelectionDAGISel.h
vendor/llvm/dist/include/llvm/CodeGen/SelectionDAGNodes.h
vendor/llvm/dist/include/llvm/CodeGen/ValueTypes.h
vendor/llvm/dist/include/llvm/Constant.h
vendor/llvm/dist/include/llvm/Constants.h
vendor/llvm/dist/include/llvm/ExecutionEngine/ExecutionEngine.h
vendor/llvm/dist/include/llvm/ExecutionEngine/GenericValue.h
vendor/llvm/dist/include/llvm/ExecutionEngine/JITEventListener.h
vendor/llvm/dist/include/llvm/ExecutionEngine/JITMemoryManager.h
vendor/llvm/dist/include/llvm/InstrTypes.h
vendor/llvm/dist/include/llvm/Instruction.def
vendor/llvm/dist/include/llvm/Instruction.h
vendor/llvm/dist/include/llvm/Instructions.h
vendor/llvm/dist/include/llvm/Intrinsics.td
vendor/llvm/dist/include/llvm/LinkAllPasses.h
vendor/llvm/dist/include/llvm/MC/MCAsmLexer.h
vendor/llvm/dist/include/llvm/MC/MCAsmParser.h
vendor/llvm/dist/include/llvm/MC/MCAssembler.h
vendor/llvm/dist/include/llvm/MC/MCDisassembler.h
vendor/llvm/dist/include/llvm/MC/MCExpr.h
vendor/llvm/dist/include/llvm/MC/MCInst.h
vendor/llvm/dist/include/llvm/MC/MCStreamer.h
vendor/llvm/dist/include/llvm/MC/MCSymbol.h
vendor/llvm/dist/include/llvm/MC/MCValue.h
vendor/llvm/dist/include/llvm/Metadata.h
vendor/llvm/dist/include/llvm/Module.h
vendor/llvm/dist/include/llvm/Pass.h
vendor/llvm/dist/include/llvm/Support/Allocator.h
vendor/llvm/dist/include/llvm/Support/ConstantRange.h
vendor/llvm/dist/include/llvm/Support/Debug.h
vendor/llvm/dist/include/llvm/Support/ELF.h
vendor/llvm/dist/include/llvm/Support/IRBuilder.h
vendor/llvm/dist/include/llvm/Support/InstVisitor.h
vendor/llvm/dist/include/llvm/Support/MathExtras.h
vendor/llvm/dist/include/llvm/Support/MemoryBuffer.h
vendor/llvm/dist/include/llvm/Support/MemoryObject.h
vendor/llvm/dist/include/llvm/Support/PointerLikeTypeTraits.h
vendor/llvm/dist/include/llvm/Support/SlowOperationInformer.h
vendor/llvm/dist/include/llvm/Support/StandardPasses.h
vendor/llvm/dist/include/llvm/Support/TargetFolder.h
vendor/llvm/dist/include/llvm/Support/Timer.h
vendor/llvm/dist/include/llvm/Support/raw_ostream.h
vendor/llvm/dist/include/llvm/System/Atomic.h
vendor/llvm/dist/include/llvm/System/Disassembler.h
vendor/llvm/dist/include/llvm/System/Memory.h
vendor/llvm/dist/include/llvm/System/TimeValue.h
vendor/llvm/dist/include/llvm/Target/SubtargetFeature.h
vendor/llvm/dist/include/llvm/Target/Target.td
vendor/llvm/dist/include/llvm/Target/TargetData.h
vendor/llvm/dist/include/llvm/Target/TargetInstrDesc.h
vendor/llvm/dist/include/llvm/Target/TargetInstrInfo.h
vendor/llvm/dist/include/llvm/Target/TargetJITInfo.h
vendor/llvm/dist/include/llvm/Target/TargetLowering.h
vendor/llvm/dist/include/llvm/Target/TargetSelectionDAG.td
vendor/llvm/dist/include/llvm/Transforms/IPO.h
vendor/llvm/dist/include/llvm/Transforms/Scalar.h
vendor/llvm/dist/include/llvm/Transforms/Utils/BasicBlockUtils.h
vendor/llvm/dist/include/llvm/Transforms/Utils/SSAUpdater.h
vendor/llvm/dist/include/llvm/Transforms/Utils/ValueMapper.h
vendor/llvm/dist/include/llvm/Type.h
vendor/llvm/dist/include/llvm/TypeSymbolTable.h
vendor/llvm/dist/include/llvm/Value.h
vendor/llvm/dist/include/llvm/ValueSymbolTable.h
vendor/llvm/dist/lib/Analysis/AliasAnalysis.cpp
vendor/llvm/dist/lib/Analysis/AliasAnalysisCounter.cpp
vendor/llvm/dist/lib/Analysis/AliasAnalysisEvaluator.cpp
vendor/llvm/dist/lib/Analysis/AliasDebugger.cpp
vendor/llvm/dist/lib/Analysis/AliasSetTracker.cpp
vendor/llvm/dist/lib/Analysis/BasicAliasAnalysis.cpp
vendor/llvm/dist/lib/Analysis/CFGPrinter.cpp
vendor/llvm/dist/lib/Analysis/CMakeLists.txt
vendor/llvm/dist/lib/Analysis/CaptureTracking.cpp
vendor/llvm/dist/lib/Analysis/ConstantFolding.cpp
vendor/llvm/dist/lib/Analysis/DbgInfoPrinter.cpp
vendor/llvm/dist/lib/Analysis/DebugInfo.cpp
vendor/llvm/dist/lib/Analysis/IPA/Andersens.cpp
vendor/llvm/dist/lib/Analysis/IPA/CallGraph.cpp
vendor/llvm/dist/lib/Analysis/IPA/GlobalsModRef.cpp
vendor/llvm/dist/lib/Analysis/InlineCost.cpp
vendor/llvm/dist/lib/Analysis/InstCount.cpp
vendor/llvm/dist/lib/Analysis/MemoryDependenceAnalysis.cpp
vendor/llvm/dist/lib/Analysis/PointerTracking.cpp
vendor/llvm/dist/lib/Analysis/ProfileEstimatorPass.cpp
vendor/llvm/dist/lib/Analysis/ProfileInfo.cpp
vendor/llvm/dist/lib/Analysis/ProfileInfoLoaderPass.cpp
vendor/llvm/dist/lib/Analysis/ProfileVerifierPass.cpp
vendor/llvm/dist/lib/Analysis/ScalarEvolution.cpp
vendor/llvm/dist/lib/Analysis/ScalarEvolutionAliasAnalysis.cpp
vendor/llvm/dist/lib/Analysis/SparsePropagation.cpp
vendor/llvm/dist/lib/Analysis/ValueTracking.cpp
vendor/llvm/dist/lib/AsmParser/LLLexer.cpp
vendor/llvm/dist/lib/AsmParser/LLParser.cpp
vendor/llvm/dist/lib/AsmParser/LLParser.h
vendor/llvm/dist/lib/AsmParser/LLToken.h
vendor/llvm/dist/lib/Bitcode/Reader/BitcodeReader.cpp
vendor/llvm/dist/lib/Bitcode/Reader/BitcodeReader.h
vendor/llvm/dist/lib/Bitcode/Writer/BitcodeWriter.cpp
vendor/llvm/dist/lib/Bitcode/Writer/ValueEnumerator.cpp
vendor/llvm/dist/lib/Bitcode/Writer/ValueEnumerator.h
vendor/llvm/dist/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfDebug.h
vendor/llvm/dist/lib/CodeGen/AsmPrinter/OcamlGCPrinter.cpp
vendor/llvm/dist/lib/CodeGen/BranchFolding.cpp
vendor/llvm/dist/lib/CodeGen/CMakeLists.txt
vendor/llvm/dist/lib/CodeGen/DeadMachineInstructionElim.cpp
vendor/llvm/dist/lib/CodeGen/DwarfEHPrepare.cpp
vendor/llvm/dist/lib/CodeGen/ELF.h
vendor/llvm/dist/lib/CodeGen/ExactHazardRecognizer.cpp
vendor/llvm/dist/lib/CodeGen/GCMetadata.cpp
vendor/llvm/dist/lib/CodeGen/GCStrategy.cpp
vendor/llvm/dist/lib/CodeGen/IfConversion.cpp
vendor/llvm/dist/lib/CodeGen/LLVMTargetMachine.cpp
vendor/llvm/dist/lib/CodeGen/LatencyPriorityQueue.cpp
vendor/llvm/dist/lib/CodeGen/LiveInterval.cpp
vendor/llvm/dist/lib/CodeGen/LiveIntervalAnalysis.cpp
vendor/llvm/dist/lib/CodeGen/LiveStackAnalysis.cpp
vendor/llvm/dist/lib/CodeGen/LowerSubregs.cpp
vendor/llvm/dist/lib/CodeGen/MachineBasicBlock.cpp
vendor/llvm/dist/lib/CodeGen/MachineFunction.cpp
vendor/llvm/dist/lib/CodeGen/MachineInstr.cpp
vendor/llvm/dist/lib/CodeGen/MachineLICM.cpp
vendor/llvm/dist/lib/CodeGen/MachineSink.cpp
vendor/llvm/dist/lib/CodeGen/MachineVerifier.cpp
vendor/llvm/dist/lib/CodeGen/OcamlGC.cpp
vendor/llvm/dist/lib/CodeGen/PostRASchedulerList.cpp
vendor/llvm/dist/lib/CodeGen/PreAllocSplitting.cpp
vendor/llvm/dist/lib/CodeGen/PrologEpilogInserter.cpp
vendor/llvm/dist/lib/CodeGen/PseudoSourceValue.cpp
vendor/llvm/dist/lib/CodeGen/RegAllocLinearScan.cpp
vendor/llvm/dist/lib/CodeGen/RegAllocLocal.cpp
vendor/llvm/dist/lib/CodeGen/RegAllocPBQP.cpp
vendor/llvm/dist/lib/CodeGen/RegisterScavenging.cpp
vendor/llvm/dist/lib/CodeGen/ScheduleDAG.cpp
vendor/llvm/dist/lib/CodeGen/ScheduleDAGEmit.cpp
vendor/llvm/dist/lib/CodeGen/ScheduleDAGInstrs.cpp
vendor/llvm/dist/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
vendor/llvm/dist/lib/CodeGen/SelectionDAG/InstrEmitter.cpp
vendor/llvm/dist/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
vendor/llvm/dist/lib/CodeGen/SelectionDAG/LegalizeTypes.cpp
vendor/llvm/dist/lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp
vendor/llvm/dist/lib/CodeGen/SelectionDAG/ScheduleDAGList.cpp
vendor/llvm/dist/lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp
vendor/llvm/dist/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.h
vendor/llvm/dist/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
vendor/llvm/dist/lib/CodeGen/SelectionDAG/SelectionDAGBuild.cpp
vendor/llvm/dist/lib/CodeGen/SelectionDAG/SelectionDAGBuild.h
vendor/llvm/dist/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
vendor/llvm/dist/lib/CodeGen/SelectionDAG/TargetLowering.cpp
vendor/llvm/dist/lib/CodeGen/ShadowStackGC.cpp
vendor/llvm/dist/lib/CodeGen/SimpleRegisterCoalescing.cpp
vendor/llvm/dist/lib/CodeGen/SimpleRegisterCoalescing.h
vendor/llvm/dist/lib/CodeGen/SjLjEHPrepare.cpp
vendor/llvm/dist/lib/CodeGen/Spiller.cpp
vendor/llvm/dist/lib/CodeGen/StackProtector.cpp
vendor/llvm/dist/lib/CodeGen/StackSlotColoring.cpp
vendor/llvm/dist/lib/CodeGen/StrongPHIElimination.cpp
vendor/llvm/dist/lib/CodeGen/TwoAddressInstructionPass.cpp
vendor/llvm/dist/lib/CodeGen/UnreachableBlockElim.cpp
vendor/llvm/dist/lib/CodeGen/VirtRegMap.cpp
vendor/llvm/dist/lib/CodeGen/VirtRegMap.h
vendor/llvm/dist/lib/CodeGen/VirtRegRewriter.cpp
vendor/llvm/dist/lib/ExecutionEngine/ExecutionEngine.cpp
vendor/llvm/dist/lib/ExecutionEngine/Interpreter/Execution.cpp
vendor/llvm/dist/lib/ExecutionEngine/Interpreter/Interpreter.h
vendor/llvm/dist/lib/ExecutionEngine/JIT/JIT.cpp
vendor/llvm/dist/lib/ExecutionEngine/JIT/JIT.h
vendor/llvm/dist/lib/ExecutionEngine/JIT/JITDebugRegisterer.h
vendor/llvm/dist/lib/ExecutionEngine/JIT/JITEmitter.cpp
vendor/llvm/dist/lib/ExecutionEngine/JIT/OProfileJITEventListener.cpp
vendor/llvm/dist/lib/Linker/LinkModules.cpp
vendor/llvm/dist/lib/MC/MCAsmInfo.cpp
vendor/llvm/dist/lib/Support/APFloat.cpp
vendor/llvm/dist/lib/Support/Allocator.cpp
vendor/llvm/dist/lib/Support/Debug.cpp
vendor/llvm/dist/lib/Support/MemoryBuffer.cpp
vendor/llvm/dist/lib/System/DynamicLibrary.cpp
vendor/llvm/dist/lib/System/Path.cpp
vendor/llvm/dist/lib/System/Unix/Memory.inc
vendor/llvm/dist/lib/System/Unix/Process.inc
vendor/llvm/dist/lib/System/Unix/Signals.inc
vendor/llvm/dist/lib/System/Win32/Memory.inc
vendor/llvm/dist/lib/Target/ARM/ARM.h
vendor/llvm/dist/lib/Target/ARM/ARM.td
vendor/llvm/dist/lib/Target/ARM/ARMBaseInstrInfo.cpp
vendor/llvm/dist/lib/Target/ARM/ARMBaseInstrInfo.h
vendor/llvm/dist/lib/Target/ARM/ARMBaseRegisterInfo.cpp
vendor/llvm/dist/lib/Target/ARM/ARMBaseRegisterInfo.h
vendor/llvm/dist/lib/Target/ARM/ARMCallingConv.td
vendor/llvm/dist/lib/Target/ARM/ARMCodeEmitter.cpp
vendor/llvm/dist/lib/Target/ARM/ARMConstantIslandPass.cpp
vendor/llvm/dist/lib/Target/ARM/ARMConstantPoolValue.cpp
vendor/llvm/dist/lib/Target/ARM/ARMConstantPoolValue.h
vendor/llvm/dist/lib/Target/ARM/ARMISelDAGToDAG.cpp
vendor/llvm/dist/lib/Target/ARM/ARMISelLowering.cpp
vendor/llvm/dist/lib/Target/ARM/ARMISelLowering.h
vendor/llvm/dist/lib/Target/ARM/ARMInstrFormats.td
vendor/llvm/dist/lib/Target/ARM/ARMInstrInfo.cpp
vendor/llvm/dist/lib/Target/ARM/ARMInstrInfo.h
vendor/llvm/dist/lib/Target/ARM/ARMInstrInfo.td
vendor/llvm/dist/lib/Target/ARM/ARMInstrNEON.td
vendor/llvm/dist/lib/Target/ARM/ARMInstrThumb.td
vendor/llvm/dist/lib/Target/ARM/ARMInstrThumb2.td
vendor/llvm/dist/lib/Target/ARM/ARMInstrVFP.td
vendor/llvm/dist/lib/Target/ARM/ARMLoadStoreOptimizer.cpp
vendor/llvm/dist/lib/Target/ARM/ARMRegisterInfo.td
vendor/llvm/dist/lib/Target/ARM/ARMSubtarget.h
vendor/llvm/dist/lib/Target/ARM/ARMTargetMachine.cpp
vendor/llvm/dist/lib/Target/ARM/ARMTargetMachine.h
vendor/llvm/dist/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
vendor/llvm/dist/lib/Target/ARM/AsmPrinter/ARMAsmPrinter.cpp
vendor/llvm/dist/lib/Target/ARM/AsmPrinter/ARMInstPrinter.h
vendor/llvm/dist/lib/Target/ARM/AsmPrinter/ARMMCInstLower.cpp
vendor/llvm/dist/lib/Target/ARM/CMakeLists.txt
vendor/llvm/dist/lib/Target/ARM/NEONPreAllocPass.cpp
vendor/llvm/dist/lib/Target/ARM/README.txt
vendor/llvm/dist/lib/Target/ARM/Thumb1InstrInfo.cpp
vendor/llvm/dist/lib/Target/ARM/Thumb1RegisterInfo.cpp
vendor/llvm/dist/lib/Target/ARM/Thumb1RegisterInfo.h
vendor/llvm/dist/lib/Target/ARM/Thumb2ITBlockPass.cpp
vendor/llvm/dist/lib/Target/ARM/Thumb2InstrInfo.cpp
vendor/llvm/dist/lib/Target/ARM/Thumb2RegisterInfo.cpp
vendor/llvm/dist/lib/Target/ARM/Thumb2RegisterInfo.h
vendor/llvm/dist/lib/Target/ARM/Thumb2SizeReduction.cpp
vendor/llvm/dist/lib/Target/Alpha/AlphaBranchSelector.cpp
vendor/llvm/dist/lib/Target/Alpha/AlphaCodeEmitter.cpp
vendor/llvm/dist/lib/Target/Alpha/AlphaISelLowering.cpp
vendor/llvm/dist/lib/Target/Alpha/AlphaISelLowering.h
vendor/llvm/dist/lib/Target/Alpha/AlphaInstrInfo.td
vendor/llvm/dist/lib/Target/Alpha/AsmPrinter/AlphaAsmPrinter.cpp
vendor/llvm/dist/lib/Target/Blackfin/AsmPrinter/BlackfinAsmPrinter.cpp
vendor/llvm/dist/lib/Target/Blackfin/BlackfinInstrInfo.td
vendor/llvm/dist/lib/Target/CBackend/CBackend.cpp
vendor/llvm/dist/lib/Target/CellSPU/AsmPrinter/SPUAsmPrinter.cpp
vendor/llvm/dist/lib/Target/CellSPU/SPU.h
vendor/llvm/dist/lib/Target/CppBackend/CPPBackend.cpp
vendor/llvm/dist/lib/Target/MSIL/MSILWriter.cpp
vendor/llvm/dist/lib/Target/MSP430/AsmPrinter/CMakeLists.txt
vendor/llvm/dist/lib/Target/MSP430/AsmPrinter/MSP430AsmPrinter.cpp
vendor/llvm/dist/lib/Target/MSP430/MSP430InstrInfo.td
vendor/llvm/dist/lib/Target/Mips/AsmPrinter/MipsAsmPrinter.cpp
vendor/llvm/dist/lib/Target/Mips/MipsISelDAGToDAG.cpp
vendor/llvm/dist/lib/Target/Mips/MipsISelLowering.cpp
vendor/llvm/dist/lib/Target/Mips/MipsISelLowering.h
vendor/llvm/dist/lib/Target/Mips/MipsInstrFPU.td
vendor/llvm/dist/lib/Target/Mips/MipsInstrInfo.td
vendor/llvm/dist/lib/Target/PIC16/AsmPrinter/PIC16AsmPrinter.cpp
vendor/llvm/dist/lib/Target/PIC16/AsmPrinter/PIC16AsmPrinter.h
vendor/llvm/dist/lib/Target/PIC16/PIC16ABINames.h
vendor/llvm/dist/lib/Target/PIC16/PIC16InstrInfo.cpp
vendor/llvm/dist/lib/Target/PIC16/PIC16InstrInfo.h
vendor/llvm/dist/lib/Target/PIC16/PIC16InstrInfo.td
vendor/llvm/dist/lib/Target/PIC16/PIC16MemSelOpt.cpp
vendor/llvm/dist/lib/Target/PIC16/PIC16Passes/Makefile
vendor/llvm/dist/lib/Target/PIC16/PIC16TargetObjectFile.cpp
vendor/llvm/dist/lib/Target/PIC16/PIC16TargetObjectFile.h
vendor/llvm/dist/lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp
vendor/llvm/dist/lib/Target/PowerPC/PPCBranchSelector.cpp
vendor/llvm/dist/lib/Target/PowerPC/PPCCodeEmitter.cpp
vendor/llvm/dist/lib/Target/PowerPC/PPCISelDAGToDAG.cpp
vendor/llvm/dist/lib/Target/PowerPC/PPCInstr64Bit.td
vendor/llvm/dist/lib/Target/PowerPC/PPCInstrInfo.td
vendor/llvm/dist/lib/Target/README.txt
vendor/llvm/dist/lib/Target/Sparc/AsmPrinter/SparcAsmPrinter.cpp
vendor/llvm/dist/lib/Target/Sparc/SparcInstrInfo.td
vendor/llvm/dist/lib/Target/SystemZ/AsmPrinter/SystemZAsmPrinter.cpp
vendor/llvm/dist/lib/Target/SystemZ/SystemZISelLowering.cpp
vendor/llvm/dist/lib/Target/SystemZ/SystemZISelLowering.h
vendor/llvm/dist/lib/Target/SystemZ/SystemZInstrFP.td
vendor/llvm/dist/lib/Target/SystemZ/SystemZInstrInfo.td
vendor/llvm/dist/lib/Target/X86/AsmPrinter/X86MCInstLower.cpp
vendor/llvm/dist/lib/Target/X86/README.txt
vendor/llvm/dist/lib/Target/X86/X86CodeEmitter.cpp
vendor/llvm/dist/lib/Target/X86/X86FloatingPoint.cpp
vendor/llvm/dist/lib/Target/X86/X86FloatingPointRegKill.cpp
vendor/llvm/dist/lib/Target/X86/X86ISelDAGToDAG.cpp
vendor/llvm/dist/lib/Target/X86/X86ISelLowering.cpp
vendor/llvm/dist/lib/Target/X86/X86ISelLowering.h
vendor/llvm/dist/lib/Target/X86/X86Instr64bit.td
vendor/llvm/dist/lib/Target/X86/X86InstrFPStack.td
vendor/llvm/dist/lib/Target/X86/X86InstrInfo.cpp
vendor/llvm/dist/lib/Target/X86/X86InstrInfo.h
vendor/llvm/dist/lib/Target/X86/X86InstrInfo.td
vendor/llvm/dist/lib/Target/X86/X86InstrMMX.td
vendor/llvm/dist/lib/Target/X86/X86InstrSSE.td
vendor/llvm/dist/lib/Target/X86/X86RegisterInfo.cpp
vendor/llvm/dist/lib/Target/XCore/AsmPrinter/XCoreAsmPrinter.cpp
vendor/llvm/dist/lib/Target/XCore/XCoreInstrInfo.td
vendor/llvm/dist/lib/Transforms/IPO/ArgumentPromotion.cpp
vendor/llvm/dist/lib/Transforms/IPO/CMakeLists.txt
vendor/llvm/dist/lib/Transforms/IPO/ConstantMerge.cpp
vendor/llvm/dist/lib/Transforms/IPO/DeadArgumentElimination.cpp
vendor/llvm/dist/lib/Transforms/IPO/DeadTypeElimination.cpp
vendor/llvm/dist/lib/Transforms/IPO/ExtractGV.cpp
vendor/llvm/dist/lib/Transforms/IPO/FunctionAttrs.cpp
vendor/llvm/dist/lib/Transforms/IPO/GlobalDCE.cpp
vendor/llvm/dist/lib/Transforms/IPO/GlobalOpt.cpp
vendor/llvm/dist/lib/Transforms/IPO/IPConstantPropagation.cpp
vendor/llvm/dist/lib/Transforms/IPO/IPO.cpp
vendor/llvm/dist/lib/Transforms/IPO/InlineAlways.cpp
vendor/llvm/dist/lib/Transforms/IPO/InlineSimple.cpp
vendor/llvm/dist/lib/Transforms/IPO/Internalize.cpp
vendor/llvm/dist/lib/Transforms/IPO/LoopExtractor.cpp
vendor/llvm/dist/lib/Transforms/IPO/LowerSetJmp.cpp
vendor/llvm/dist/lib/Transforms/IPO/MergeFunctions.cpp
vendor/llvm/dist/lib/Transforms/IPO/PartialInlining.cpp
vendor/llvm/dist/lib/Transforms/IPO/PartialSpecialization.cpp
vendor/llvm/dist/lib/Transforms/IPO/PruneEH.cpp
vendor/llvm/dist/lib/Transforms/IPO/StripDeadPrototypes.cpp
vendor/llvm/dist/lib/Transforms/IPO/StripSymbols.cpp
vendor/llvm/dist/lib/Transforms/IPO/StructRetPromotion.cpp
vendor/llvm/dist/lib/Transforms/Instrumentation/BlockProfiling.cpp
vendor/llvm/dist/lib/Transforms/Instrumentation/EdgeProfiling.cpp
vendor/llvm/dist/lib/Transforms/Instrumentation/OptimalEdgeProfiling.cpp
vendor/llvm/dist/lib/Transforms/Instrumentation/RSProfiling.cpp
vendor/llvm/dist/lib/Transforms/Scalar/CMakeLists.txt
vendor/llvm/dist/lib/Transforms/Scalar/CodeGenPrepare.cpp
vendor/llvm/dist/lib/Transforms/Scalar/CondPropagate.cpp
vendor/llvm/dist/lib/Transforms/Scalar/DeadStoreElimination.cpp
vendor/llvm/dist/lib/Transforms/Scalar/GVN.cpp
vendor/llvm/dist/lib/Transforms/Scalar/IndVarSimplify.cpp
vendor/llvm/dist/lib/Transforms/Scalar/InstructionCombining.cpp
vendor/llvm/dist/lib/Transforms/Scalar/LoopDeletion.cpp
vendor/llvm/dist/lib/Transforms/Scalar/LoopIndexSplit.cpp
vendor/llvm/dist/lib/Transforms/Scalar/LoopRotation.cpp
vendor/llvm/dist/lib/Transforms/Scalar/LoopStrengthReduce.cpp
vendor/llvm/dist/lib/Transforms/Scalar/LoopUnswitch.cpp
vendor/llvm/dist/lib/Transforms/Scalar/SCCP.cpp
vendor/llvm/dist/lib/Transforms/Scalar/ScalarReplAggregates.cpp
vendor/llvm/dist/lib/Transforms/Scalar/SimplifyCFGPass.cpp
vendor/llvm/dist/lib/Transforms/Scalar/SimplifyLibCalls.cpp
vendor/llvm/dist/lib/Transforms/Scalar/TailDuplication.cpp
vendor/llvm/dist/lib/Transforms/Utils/BasicBlockUtils.cpp
vendor/llvm/dist/lib/Transforms/Utils/BasicInliner.cpp
vendor/llvm/dist/lib/Transforms/Utils/BreakCriticalEdges.cpp
vendor/llvm/dist/lib/Transforms/Utils/CMakeLists.txt
vendor/llvm/dist/lib/Transforms/Utils/CloneFunction.cpp
vendor/llvm/dist/lib/Transforms/Utils/CloneModule.cpp
vendor/llvm/dist/lib/Transforms/Utils/CodeExtractor.cpp
vendor/llvm/dist/lib/Transforms/Utils/InlineFunction.cpp
vendor/llvm/dist/lib/Transforms/Utils/Local.cpp
vendor/llvm/dist/lib/Transforms/Utils/LoopSimplify.cpp
vendor/llvm/dist/lib/Transforms/Utils/LowerInvoke.cpp
vendor/llvm/dist/lib/Transforms/Utils/LowerSwitch.cpp
vendor/llvm/dist/lib/Transforms/Utils/Mem2Reg.cpp
vendor/llvm/dist/lib/Transforms/Utils/PromoteMemoryToRegister.cpp
vendor/llvm/dist/lib/Transforms/Utils/SSI.cpp
vendor/llvm/dist/lib/Transforms/Utils/SimplifyCFG.cpp
vendor/llvm/dist/lib/Transforms/Utils/ValueMapper.cpp
vendor/llvm/dist/lib/VMCore/AsmWriter.cpp
vendor/llvm/dist/lib/VMCore/BasicBlock.cpp
vendor/llvm/dist/lib/VMCore/ConstantFold.cpp
vendor/llvm/dist/lib/VMCore/Constants.cpp
vendor/llvm/dist/lib/VMCore/ConstantsContext.h
vendor/llvm/dist/lib/VMCore/Core.cpp
vendor/llvm/dist/lib/VMCore/Dominators.cpp
vendor/llvm/dist/lib/VMCore/Function.cpp
vendor/llvm/dist/lib/VMCore/Globals.cpp
vendor/llvm/dist/lib/VMCore/Instruction.cpp
vendor/llvm/dist/lib/VMCore/Instructions.cpp
vendor/llvm/dist/lib/VMCore/LLVMContextImpl.h
vendor/llvm/dist/lib/VMCore/LeakDetector.cpp
vendor/llvm/dist/lib/VMCore/LeaksContext.h
vendor/llvm/dist/lib/VMCore/Metadata.cpp
vendor/llvm/dist/lib/VMCore/PassManager.cpp
vendor/llvm/dist/lib/VMCore/PrintModulePass.cpp
vendor/llvm/dist/lib/VMCore/Type.cpp
vendor/llvm/dist/lib/VMCore/TypeSymbolTable.cpp
vendor/llvm/dist/lib/VMCore/Value.cpp
vendor/llvm/dist/lib/VMCore/Verifier.cpp
vendor/llvm/dist/projects/sample/lib/sample/sample.c
vendor/llvm/dist/test/Analysis/BasicAA/2006-03-03-BadArraySubscript.ll
vendor/llvm/dist/test/Analysis/BasicAA/2009-10-13-AtomicModRef.ll
vendor/llvm/dist/test/Analysis/BasicAA/featuretest.ll
vendor/llvm/dist/test/Analysis/BasicAA/global-size.ll
vendor/llvm/dist/test/Analysis/BasicAA/modref.ll
vendor/llvm/dist/test/Analysis/BasicAA/store-promote.ll
vendor/llvm/dist/test/Analysis/LoopInfo/2003-05-15-NestingProblem.ll
vendor/llvm/dist/test/Analysis/ScalarEvolution/2007-11-18-OrInstruction.ll
vendor/llvm/dist/test/Analysis/ScalarEvolution/2008-07-29-SGTTripCount.ll
vendor/llvm/dist/test/Analysis/ScalarEvolution/2008-07-29-SMinExpr.ll
vendor/llvm/dist/test/Analysis/ScalarEvolution/2008-08-04-IVOverflow.ll
vendor/llvm/dist/test/Analysis/ScalarEvolution/2008-08-04-LongAddRec.ll
vendor/llvm/dist/test/Analysis/ScalarEvolution/2009-05-09-PointerEdgeCount.ll
vendor/llvm/dist/test/CodeGen/ARM/alloca.ll
vendor/llvm/dist/test/CodeGen/ARM/arguments.ll
vendor/llvm/dist/test/CodeGen/ARM/arguments_f64_backfill.ll
vendor/llvm/dist/test/CodeGen/ARM/arm-negative-stride.ll
vendor/llvm/dist/test/CodeGen/ARM/bfc.ll
vendor/llvm/dist/test/CodeGen/ARM/call.ll
vendor/llvm/dist/test/CodeGen/ARM/carry.ll
vendor/llvm/dist/test/CodeGen/ARM/constants.ll
vendor/llvm/dist/test/CodeGen/ARM/fmacs.ll
vendor/llvm/dist/test/CodeGen/ARM/fnmacs.ll
vendor/llvm/dist/test/CodeGen/ARM/fpmem.ll
vendor/llvm/dist/test/CodeGen/ARM/ispositive.ll
vendor/llvm/dist/test/CodeGen/ARM/ldm.ll
vendor/llvm/dist/test/CodeGen/ARM/ldr.ll
vendor/llvm/dist/test/CodeGen/ARM/long.ll
vendor/llvm/dist/test/CodeGen/ARM/long_shift.ll
vendor/llvm/dist/test/CodeGen/ARM/remat.ll
vendor/llvm/dist/test/CodeGen/ARM/str_post.ll
vendor/llvm/dist/test/CodeGen/ARM/tls2.ll
vendor/llvm/dist/test/CodeGen/CPP/llvm2cpp.ll
vendor/llvm/dist/test/CodeGen/Generic/intrinsics.ll
vendor/llvm/dist/test/CodeGen/Thumb2/2009-08-04-SubregLoweringBug.ll
vendor/llvm/dist/test/CodeGen/Thumb2/thumb2-bcc.ll
vendor/llvm/dist/test/CodeGen/Thumb2/thumb2-bfc.ll
vendor/llvm/dist/test/CodeGen/Thumb2/thumb2-branch.ll
vendor/llvm/dist/test/CodeGen/Thumb2/thumb2-clz.ll
vendor/llvm/dist/test/CodeGen/Thumb2/thumb2-cmn2.ll
vendor/llvm/dist/test/CodeGen/Thumb2/thumb2-eor2.ll
vendor/llvm/dist/test/CodeGen/Thumb2/thumb2-mov.ll
vendor/llvm/dist/test/CodeGen/Thumb2/thumb2-str_post.ll
vendor/llvm/dist/test/CodeGen/X86/2007-11-30-LoadFolding-Bug.ll
vendor/llvm/dist/test/CodeGen/X86/2008-02-18-TailMergingBug.ll
vendor/llvm/dist/test/CodeGen/X86/2008-05-12-tailmerge-5.ll
vendor/llvm/dist/test/CodeGen/X86/break-anti-dependencies.ll
vendor/llvm/dist/test/CodeGen/X86/convert-2-addr-3-addr-inc64.ll
vendor/llvm/dist/test/CodeGen/X86/pic-load-remat.ll
vendor/llvm/dist/test/CodeGen/X86/sink-hoist.ll
vendor/llvm/dist/test/CodeGen/X86/vec_ins_extract.ll
vendor/llvm/dist/test/CodeGen/X86/x86-64-pic-10.ll
vendor/llvm/dist/test/Makefile
vendor/llvm/dist/test/Other/2003-02-19-LoopInfoNestingBug.ll
vendor/llvm/dist/test/Scripts/macho-dump
vendor/llvm/dist/test/Transforms/ArgumentPromotion/aggregate-promote.ll
vendor/llvm/dist/test/Transforms/ArgumentPromotion/basictest.ll
vendor/llvm/dist/test/Transforms/ArgumentPromotion/byval.ll
vendor/llvm/dist/test/Transforms/ArgumentPromotion/chained.ll
vendor/llvm/dist/test/Transforms/ArgumentPromotion/control-flow2.ll
vendor/llvm/dist/test/Transforms/ConstProp/float-to-ptr-cast.ll
vendor/llvm/dist/test/Transforms/ConstProp/loads.ll
vendor/llvm/dist/test/Transforms/DeadStoreElimination/2008-07-28-load-store.ll
vendor/llvm/dist/test/Transforms/DeadStoreElimination/PartialStore.ll
vendor/llvm/dist/test/Transforms/DeadStoreElimination/context-sensitive.ll
vendor/llvm/dist/test/Transforms/DeadStoreElimination/simple.ll
vendor/llvm/dist/test/Transforms/GlobalOpt/globalsra-partial.ll
vendor/llvm/dist/test/Transforms/GlobalOpt/globalsra.ll
vendor/llvm/dist/test/Transforms/GlobalOpt/malloc-promote-1.ll
vendor/llvm/dist/test/Transforms/IndVarSimplify/preserve-gep-loop-variant.ll
vendor/llvm/dist/test/Transforms/IndVarSimplify/preserve-gep-remainder.ll
vendor/llvm/dist/test/Transforms/Inline/basictest.ll
vendor/llvm/dist/test/Transforms/Inline/callgraph-update.ll
vendor/llvm/dist/test/Transforms/InstCombine/2003-11-13-ConstExprCastCall.ll
vendor/llvm/dist/test/Transforms/InstCombine/2007-10-10-EliminateMemCpy.ll
vendor/llvm/dist/test/Transforms/InstCombine/add-shrink.ll
vendor/llvm/dist/test/Transforms/InstCombine/add-sitofp.ll
vendor/llvm/dist/test/Transforms/InstCombine/align-2d-gep.ll
vendor/llvm/dist/test/Transforms/InstCombine/align-addr.ll
vendor/llvm/dist/test/Transforms/InstCombine/align-inc.ll
vendor/llvm/dist/test/Transforms/InstCombine/alloca.ll
vendor/llvm/dist/test/Transforms/InstCombine/call.ll
vendor/llvm/dist/test/Transforms/InstCombine/cast-load-gep.ll
vendor/llvm/dist/test/Transforms/InstCombine/cast.ll
vendor/llvm/dist/test/Transforms/InstCombine/cast2.ll
vendor/llvm/dist/test/Transforms/InstCombine/constant-fold-gep.ll
vendor/llvm/dist/test/Transforms/InstCombine/fold-bin-operand.ll
vendor/llvm/dist/test/Transforms/InstCombine/fp-ret-bitcast.ll
vendor/llvm/dist/test/Transforms/InstCombine/loadstore-alignment.ll
vendor/llvm/dist/test/Transforms/InstCombine/malloc-free-delete.ll
vendor/llvm/dist/test/Transforms/InstCombine/or.ll
vendor/llvm/dist/test/Transforms/InstCombine/phi.ll
vendor/llvm/dist/test/Transforms/InstCombine/preserve-sminmax.ll
vendor/llvm/dist/test/Transforms/InstCombine/ptr-int-cast.ll
vendor/llvm/dist/test/Transforms/InstCombine/store.ll
vendor/llvm/dist/test/Transforms/InstCombine/sub.ll
vendor/llvm/dist/test/Transforms/JumpThreading/no-irreducible-loops.ll
vendor/llvm/dist/test/Transforms/LICM/2008-07-22-LoadGlobalConstant.ll
vendor/llvm/dist/test/Transforms/LICM/Preserve-LCSSA.ll
vendor/llvm/dist/test/Transforms/LoopRotate/2009-01-25-SingleEntryPhi.ll
vendor/llvm/dist/test/Transforms/LoopRotate/LRCrash-1.ll
vendor/llvm/dist/test/Transforms/LoopRotate/LRCrash-2.ll
vendor/llvm/dist/test/Transforms/LoopRotate/LRCrash-3.ll
vendor/llvm/dist/test/Transforms/LoopRotate/LRCrash-4.ll
vendor/llvm/dist/test/Transforms/LoopRotate/LRCrash-5.ll
vendor/llvm/dist/test/Transforms/LoopRotate/PhiRename-1.ll
vendor/llvm/dist/test/Transforms/LoopRotate/PhiSelfRefernce-1.ll
vendor/llvm/dist/test/Transforms/LoopRotate/pr2639.ll
vendor/llvm/dist/test/Transforms/LoopRotate/preserve-scev.ll
vendor/llvm/dist/test/Transforms/LoopSimplify/merge-exits.ll
vendor/llvm/dist/test/Transforms/Mem2Reg/crash.ll
vendor/llvm/dist/test/Transforms/MemCpyOpt/2008-03-13-ReturnSlotBitcast.ll
vendor/llvm/dist/test/Transforms/MemCpyOpt/align.ll
vendor/llvm/dist/test/Transforms/SCCP/ipsccp-basic.ll
vendor/llvm/dist/test/Transforms/SCCP/loadtest.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/2003-05-29-ArrayFail.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/2006-11-07-InvalidArrayPromote.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/2008-06-05-loadstore-agg.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/2008-09-22-vector-gep.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/2009-03-04-MemCpyAlign.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/DifferingTypes.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/arraytest.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/basictest.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/bitfield-sroa.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/copy-aggregate.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/debuginfo.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/load-store-aggregate.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/memcpy-from-global.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/not-a-vector.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/union-fp-int.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/union-packed.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/vector_memcpy.ll
vendor/llvm/dist/test/Transforms/ScalarRepl/vector_promote.ll
vendor/llvm/dist/test/Transforms/SimplifyCFG/basictest.ll
vendor/llvm/dist/test/lit.cfg
vendor/llvm/dist/tools/gold/gold-plugin.cpp
vendor/llvm/dist/tools/lli/lli.cpp
vendor/llvm/dist/tools/llvm-mc/AsmLexer.h
vendor/llvm/dist/tools/llvm-mc/llvm-mc.cpp
vendor/llvm/dist/tools/llvmc/doc/LLVMC-Reference.rst
vendor/llvm/dist/tools/opt/opt.cpp
vendor/llvm/dist/unittests/ADT/StringMapTest.cpp
vendor/llvm/dist/unittests/ADT/ValueMapTest.cpp
vendor/llvm/dist/unittests/ExecutionEngine/JIT/JITEventListenerTest.cpp
vendor/llvm/dist/unittests/ExecutionEngine/JIT/JITMemoryManagerTest.cpp
vendor/llvm/dist/unittests/ExecutionEngine/JIT/JITTest.cpp
vendor/llvm/dist/unittests/ExecutionEngine/JIT/Makefile
vendor/llvm/dist/unittests/Makefile.unittest
vendor/llvm/dist/unittests/Support/ValueHandleTest.cpp
vendor/llvm/dist/unittests/Transforms/Utils/Cloning.cpp
vendor/llvm/dist/unittests/VMCore/MetadataTest.cpp
vendor/llvm/dist/utils/TableGen/CodeGenDAGPatterns.cpp
vendor/llvm/dist/utils/TableGen/CodeGenInstruction.cpp
vendor/llvm/dist/utils/TableGen/CodeGenInstruction.h
vendor/llvm/dist/utils/TableGen/DAGISelEmitter.cpp
vendor/llvm/dist/utils/TableGen/InstrInfoEmitter.cpp
vendor/llvm/dist/utils/TableGen/LLVMCConfigurationEmitter.cpp
vendor/llvm/dist/utils/TableGen/Record.cpp
vendor/llvm/dist/utils/TableGen/Record.h
vendor/llvm/dist/utils/TableGen/TGLexer.h
vendor/llvm/dist/utils/UpdateCMakeLists.pl
vendor/llvm/dist/utils/buildit/build_llvm
vendor/llvm/dist/utils/findoptdiff
vendor/llvm/dist/utils/lit/TestRunner.py
vendor/llvm/dist/utils/lit/Util.py
vendor/llvm/dist/utils/lit/lit.py
vendor/llvm/dist/utils/unittest/UnitTestMain/Makefile
vendor/llvm/dist/utils/unittest/googletest/Makefile
vendor/llvm/dist/utils/vim/llvm.vim
Modified: vendor/llvm/dist/CMakeLists.txt
==============================================================================
--- vendor/llvm/dist/CMakeLists.txt Wed Nov 4 14:19:23 2009 (r198891)
+++ vendor/llvm/dist/CMakeLists.txt Wed Nov 4 14:58:56 2009 (r198892)
@@ -319,16 +319,26 @@ if(LLVM_BUILD_EXAMPLES)
add_subdirectory(examples)
endif ()
-install(DIRECTORY include
- DESTINATION .
+install(DIRECTORY include/
+ DESTINATION include
+ FILES_MATCHING
+ PATTERN "*.def"
+ PATTERN "*.h"
+ PATTERN "*.td"
+ PATTERN "*.inc"
PATTERN ".svn" EXCLUDE
- PATTERN "*.cmake" EXCLUDE
- PATTERN "*.in" EXCLUDE
- PATTERN "*.tmp" EXCLUDE
)
-install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/include
- DESTINATION .
+install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/include/
+ DESTINATION include
+ FILES_MATCHING
+ PATTERN "*.def"
+ PATTERN "*.h"
+ PATTERN "*.gen"
+ PATTERN "*.inc"
+ # Exclude include/llvm/CMakeFiles/intrinsics_gen.dir, matched by "*.def"
+ PATTERN "CMakeFiles" EXCLUDE
+ PATTERN ".svn" EXCLUDE
)
# TODO: make and install documentation.
Modified: vendor/llvm/dist/Makefile
==============================================================================
--- vendor/llvm/dist/Makefile Wed Nov 4 14:19:23 2009 (r198891)
+++ vendor/llvm/dist/Makefile Wed Nov 4 14:58:56 2009 (r198892)
@@ -24,7 +24,8 @@ LEVEL := .
# "llvmCore", then this is an "Apple-style" build; search for
# "Apple-style" in the comments for more info. Anything else is a
# normal build.
-ifneq ($(RC_ProjectName),llvmCore) # Normal build (not "Apple-style").
+ifneq ($(findstring llvmCore, $(RC_ProjectName)),llvmCore) # Normal build (not "Apple-style").
+
ifeq ($(BUILD_DIRS_ONLY),1)
DIRS := lib/System lib/Support utils
OPTIONAL_DIRS :=
@@ -94,6 +95,8 @@ cross-compile-build-tools:
$(Verb) if [ ! -f BuildTools/Makefile ]; then \
$(MKDIR) BuildTools; \
cd BuildTools ; \
+ unset CFLAGS ; \
+ unset CXXFLAGS ; \
$(PROJ_SRC_DIR)/configure --build=$(BUILD_TRIPLE) \
--host=$(BUILD_TRIPLE) --target=$(BUILD_TRIPLE); \
cd .. ; \
@@ -133,8 +136,7 @@ dist-hook::
$(Echo) Eliminating files constructed by configure
$(Verb) $(RM) -f \
$(TopDistDir)/include/llvm/Config/config.h \
- $(TopDistDir)/include/llvm/Support/DataTypes.h \
- $(TopDistDir)/include/llvm/Support/ThreadSupport.h
+ $(TopDistDir)/include/llvm/System/DataTypes.h
clang-only: all
tools-only: all
@@ -150,7 +152,7 @@ FilesToConfig := \
include/llvm/Config/config.h \
include/llvm/Config/Targets.def \
include/llvm/Config/AsmPrinters.def \
- include/llvm/Support/DataTypes.h \
+ include/llvm/System/DataTypes.h \
tools/llvmc/plugins/Base/Base.td
FilesToConfigPATH := $(addprefix $(LLVM_OBJ_ROOT)/,$(FilesToConfig))
Modified: vendor/llvm/dist/Makefile.config.in
==============================================================================
--- vendor/llvm/dist/Makefile.config.in Wed Nov 4 14:19:23 2009 (r198891)
+++ vendor/llvm/dist/Makefile.config.in Wed Nov 4 14:58:56 2009 (r198892)
@@ -250,6 +250,9 @@ RDYNAMIC := @RDYNAMIC@
#DEBUG_SYMBOLS = 1
@DEBUG_SYMBOLS@
+# The compiler flags to use for optimized builds.
+OPTIMIZE_OPTION := @OPTIMIZE_OPTION@
+
# When ENABLE_PROFILING is enabled, the llvm source base is built with profile
# information to allow gprof to be used to get execution frequencies.
#ENABLE_PROFILING = 1
@@ -320,3 +323,9 @@ ENABLE_LLVMC_DYNAMIC = 0
# support (via the -load option).
ENABLE_LLVMC_DYNAMIC_PLUGINS = 1
#@ENABLE_LLVMC_DYNAMIC_PLUGINS@
+
+# Optional flags supported by the compiler
+# -Wno-missing-field-initializers
+NO_MISSING_FIELD_INITIALIZERS = @NO_MISSING_FIELD_INITIALIZERS@
+# -Wno-variadic-macros
+NO_VARIADIC_MACROS = @NO_VARIADIC_MACROS@
Modified: vendor/llvm/dist/Makefile.rules
==============================================================================
--- vendor/llvm/dist/Makefile.rules Wed Nov 4 14:19:23 2009 (r198891)
+++ vendor/llvm/dist/Makefile.rules Wed Nov 4 14:58:56 2009 (r198892)
@@ -312,16 +312,6 @@ endif
#--------------------------------------------------------------------
CPP.Defines :=
-# OPTIMIZE_OPTION - The optimization level option we want to build LLVM with
-# this can be overridden on the make command line.
-ifndef OPTIMIZE_OPTION
- ifneq ($(HOST_OS),MingW)
- OPTIMIZE_OPTION := -O3
- else
- OPTIMIZE_OPTION := -O2
- endif
-endif
-
ifeq ($(ENABLE_OPTIMIZED),1)
BuildMode := Release
# Don't use -fomit-frame-pointer on Darwin or FreeBSD.
@@ -566,6 +556,8 @@ endif
ifeq ($(TARGET_OS),Darwin)
ifneq ($(ARCH),ARM)
TargetCommonOpts += -mmacosx-version-min=$(DARWIN_VERSION)
+ else
+ TargetCommonOpts += -marm
endif
endif
@@ -1238,7 +1230,7 @@ endif
endif
ifeq ($(HOST_OS), $(filter $(HOST_OS), Linux NetBSD FreeBSD))
-LD.Flags += -Wl,--version-script=$(LLVM_SRC_ROOT)/autoconf/ExportMap.map
+ LD.Flags += -Wl,--version-script=$(LLVM_SRC_ROOT)/autoconf/ExportMap.map
endif
endif
Modified: vendor/llvm/dist/autoconf/configure.ac
==============================================================================
--- vendor/llvm/dist/autoconf/configure.ac Wed Nov 4 14:19:23 2009 (r198891)
+++ vendor/llvm/dist/autoconf/configure.ac Wed Nov 4 14:58:56 2009 (r198892)
@@ -607,6 +607,23 @@ if test -n "$LLVMGXX" && test -z "$LLVMG
AC_MSG_ERROR([Invalid llvm-gcc. Use --with-llvmgcc when --with-llvmgxx is used]);
fi
+dnl Override the option to use for optimized builds.
+AC_ARG_WITH(optimize-option,
+ AS_HELP_STRING([--with-optimize-option],
+ [Select the compiler options to use for optimized builds]),,
+ withval=default)
+AC_MSG_CHECKING([optimization flags])
+case "$withval" in
+ default)
+ case "$llvm_cv_os_type" in
+ MingW) optimize_option=-O3 ;;
+ *) optimize_option=-O2 ;;
+ esac ;;
+ *) optimize_option="$withval" ;;
+esac
+AC_SUBST(OPTIMIZE_OPTION,$optimize_option)
+AC_MSG_RESULT([$optimize_option])
+
dnl Specify extra build options
AC_ARG_WITH(extra-options,
AS_HELP_STRING([--with-extra-options],
@@ -943,6 +960,12 @@ fi
dnl Tool compatibility is okay if we make it here.
AC_MSG_RESULT([ok])
+dnl Check optional compiler flags.
+AC_MSG_CHECKING([optional compiler flags])
+CXX_FLAG_CHECK(NO_VARIADIC_MACROS, [-Wno-variadic-macros])
+CXX_FLAG_CHECK(NO_MISSING_FIELD_INITIALIZERS, [-Wno-missing-field-initializers])
+AC_MSG_RESULT([$NO_VARIADIC_MACROS $NO_MISSING_FIELD_INITIALIZERS])
+
dnl===-----------------------------------------------------------------------===
dnl===
dnl=== SECTION 5: Check for libraries
@@ -1349,7 +1372,7 @@ AC_CONFIG_HEADERS([include/llvm/Config/c
AC_CONFIG_FILES([include/llvm/Config/Targets.def])
AC_CONFIG_FILES([include/llvm/Config/AsmPrinters.def])
AC_CONFIG_FILES([include/llvm/Config/AsmParsers.def])
-AC_CONFIG_HEADERS([include/llvm/Support/DataTypes.h])
+AC_CONFIG_HEADERS([include/llvm/System/DataTypes.h])
dnl Configure the makefile's configuration data
AC_CONFIG_FILES([Makefile.config])
Modified: vendor/llvm/dist/cmake/config-ix.cmake
==============================================================================
--- vendor/llvm/dist/cmake/config-ix.cmake Wed Nov 4 14:19:23 2009 (r198891)
+++ vendor/llvm/dist/cmake/config-ix.cmake Wed Nov 4 14:58:56 2009 (r198892)
@@ -83,9 +83,9 @@ check_symbol_exists(floorf math.h HAVE_F
check_symbol_exists(mallinfo malloc.h HAVE_MALLINFO)
check_symbol_exists(malloc_zone_statistics malloc/malloc.h
HAVE_MALLOC_ZONE_STATISTICS)
-check_symbol_exists(mkdtemp unistd.h HAVE_MKDTEMP)
-check_symbol_exists(mkstemp unistd.h HAVE_MKSTEMP)
-check_symbol_exists(mktemp unistd.h HAVE_MKTEMP)
+check_symbol_exists(mkdtemp "stdlib.h;unistd.h" HAVE_MKDTEMP)
+check_symbol_exists(mkstemp "stdlib.h;unistd.h" HAVE_MKSTEMP)
+check_symbol_exists(mktemp "stdlib.h;unistd.h" HAVE_MKTEMP)
check_symbol_exists(pthread_mutex_lock pthread.h HAVE_PTHREAD_MUTEX_LOCK)
check_symbol_exists(sbrk unistd.h HAVE_SBRK)
check_symbol_exists(strtoll stdlib.h HAVE_STRTOLL)
@@ -229,7 +229,7 @@ configure_file(
)
configure_file(
- ${LLVM_MAIN_INCLUDE_DIR}/llvm/Support/DataTypes.h.cmake
- ${LLVM_BINARY_DIR}/include/llvm/Support/DataTypes.h
+ ${LLVM_MAIN_INCLUDE_DIR}/llvm/System/DataTypes.h.cmake
+ ${LLVM_BINARY_DIR}/include/llvm/System/DataTypes.h
)
Modified: vendor/llvm/dist/cmake/modules/LLVMLibDeps.cmake
==============================================================================
--- vendor/llvm/dist/cmake/modules/LLVMLibDeps.cmake Wed Nov 4 14:19:23 2009 (r198891)
+++ vendor/llvm/dist/cmake/modules/LLVMLibDeps.cmake Wed Nov 4 14:58:56 2009 (r198892)
@@ -23,7 +23,6 @@ set(MSVC_LIB_DEPS_LLVMCodeGen LLVMAnalys
set(MSVC_LIB_DEPS_LLVMCore LLVMSupport LLVMSystem)
set(MSVC_LIB_DEPS_LLVMCppBackend LLVMCore LLVMCppBackendInfo LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMCppBackendInfo LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMDebugger LLVMAnalysis LLVMBitReader LLVMCore LLVMSupport LLVMSystem)
set(MSVC_LIB_DEPS_LLVMExecutionEngine LLVMCore LLVMSupport LLVMSystem LLVMTarget)
set(MSVC_LIB_DEPS_LLVMHello LLVMCore LLVMSupport LLVMSystem)
set(MSVC_LIB_DEPS_LLVMInstrumentation LLVMAnalysis LLVMCore LLVMScalarOpts LLVMSupport LLVMSystem LLVMTransformUtils)
Modified: vendor/llvm/dist/cmake/modules/LLVMProcessSources.cmake
==============================================================================
--- vendor/llvm/dist/cmake/modules/LLVMProcessSources.cmake Wed Nov 4 14:19:23 2009 (r198891)
+++ vendor/llvm/dist/cmake/modules/LLVMProcessSources.cmake Wed Nov 4 14:58:56 2009 (r198892)
@@ -22,6 +22,7 @@ endmacro(add_header_files)
function(llvm_process_sources OUT_VAR)
set( sources ${ARGN} )
+ llvm_check_source_file_list( ${sources} )
# Create file dependencies on the tablegenned files, if any. Seems
# that this is not strictly needed, as dependencies of the .cpp
# sources on the tablegenned .inc files are detected and handled,
@@ -37,3 +38,17 @@ function(llvm_process_sources OUT_VAR)
endif()
set( ${OUT_VAR} ${sources} PARENT_SCOPE )
endfunction(llvm_process_sources)
+
+
+function(llvm_check_source_file_list)
+ set(listed ${ARGN})
+ file(GLOB globbed *.cpp)
+ foreach(g ${globbed})
+ get_filename_component(fn ${g} NAME)
+ list(FIND listed ${fn} idx)
+ if( idx LESS 0 )
+ message(SEND_ERROR "Found unknown source file ${g}
+Please update ${CMAKE_CURRENT_SOURCE_DIR}/CMakeLists.txt\n")
+ endif()
+ endforeach()
+endfunction(llvm_check_source_file_list)
Modified: vendor/llvm/dist/configure
==============================================================================
--- vendor/llvm/dist/configure Wed Nov 4 14:19:23 2009 (r198891)
+++ vendor/llvm/dist/configure Wed Nov 4 14:58:56 2009 (r198892)
@@ -848,6 +848,7 @@ LLVM_ENUM_TARGETS
LLVM_ENUM_ASM_PRINTERS
LLVM_ENUM_ASM_PARSERS
ENABLE_CBE_PRINTF_A
+OPTIMIZE_OPTION
EXTRA_OPTIONS
BINUTILS_INCDIR
ENABLE_LLVMC_DYNAMIC
@@ -913,6 +914,8 @@ LLVMGCCCOMMAND
LLVMGXXCOMMAND
LLVMGCC
LLVMGXX
+NO_VARIADIC_MACROS
+NO_MISSING_FIELD_INITIALIZERS
USE_UDIS86
USE_OPROFILE
HAVE_PTHREAD
@@ -1595,6 +1598,8 @@ Optional Packages:
searches PATH)
--with-llvmgxx Specify location of llvm-g++ driver (default
searches PATH)
+ --with-optimize-option Select the compiler options to use for optimized
+ builds
--with-extra-options Specify additional options to compile LLVM with
--with-ocaml-libdir Specify install location for ocaml bindings (default
is stdlib)
@@ -5190,6 +5195,29 @@ echo "$as_me: error: Invalid llvm-gcc. U
fi
+# Check whether --with-optimize-option was given.
+if test "${with_optimize_option+set}" = set; then
+ withval=$with_optimize_option;
+else
+ withval=default
+fi
+
+{ echo "$as_me:$LINENO: checking optimization flags" >&5
+echo $ECHO_N "checking optimization flags... $ECHO_C" >&6; }
+case "$withval" in
+ default)
+ case "$llvm_cv_os_type" in
+ MingW) optimize_option=-O3 ;;
+ *) optimize_option=-O2 ;;
+ esac ;;
+ *) optimize_option="$withval" ;;
+esac
+OPTIMIZE_OPTION=$optimize_option
+
+{ echo "$as_me:$LINENO: result: $optimize_option" >&5
+echo "${ECHO_T}$optimize_option" >&6; }
+
+
# Check whether --with-extra-options was given.
if test "${with_extra_options+set}" = set; then
withval=$with_extra_options;
@@ -11008,7 +11036,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext < conftest.$ac_ext
+ echo '#line 13183 "configure"' > conftest.$ac_ext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
@@ -14870,11 +14898,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:14873: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:14901: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:14877: \$? = $ac_status" >&5
+ echo "$as_me:14905: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -15138,11 +15166,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:15141: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:15169: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:15145: \$? = $ac_status" >&5
+ echo "$as_me:15173: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -15242,11 +15270,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:15245: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:15273: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:15249: \$? = $ac_status" >&5
+ echo "$as_me:15277: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -17694,7 +17722,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext < conftest.$ac_ext <&5)
+ (eval echo "\"\$as_me:20193: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:20169: \$? = $ac_status" >&5
+ echo "$as_me:20197: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -20266,11 +20294,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:20269: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:20297: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:20273: \$? = $ac_status" >&5
+ echo "$as_me:20301: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -21836,11 +21864,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:21839: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:21867: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:21843: \$? = $ac_status" >&5
+ echo "$as_me:21871: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -21940,11 +21968,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:21943: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:21971: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:21947: \$? = $ac_status" >&5
+ echo "$as_me:21975: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -24175,11 +24203,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:24178: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:24206: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:24182: \$? = $ac_status" >&5
+ echo "$as_me:24210: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -24443,11 +24471,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:24446: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:24474: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:24450: \$? = $ac_status" >&5
+ echo "$as_me:24478: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -24547,11 +24575,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:24550: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:24578: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:24554: \$? = $ac_status" >&5
+ echo "$as_me:24582: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -27459,6 +27487,15 @@ fi
{ echo "$as_me:$LINENO: result: ok" >&5
echo "${ECHO_T}ok" >&6; }
+{ echo "$as_me:$LINENO: checking optional compiler flags" >&5
+echo $ECHO_N "checking optional compiler flags... $ECHO_C" >&6; }
+NO_VARIADIC_MACROS=`$CXX -Wno-variadic-macros -fsyntax-only -xc /dev/null 2>/dev/null && echo -Wno-variadic-macros`
+
+NO_MISSING_FIELD_INITIALIZERS=`$CXX -Wno-missing-field-initializers -fsyntax-only -xc /dev/null 2>/dev/null && echo -Wno-missing-field-initializers`
+
+{ echo "$as_me:$LINENO: result: $NO_VARIADIC_MACROS $NO_MISSING_FIELD_INITIALIZERS" >&5
+echo "${ECHO_T}$NO_VARIADIC_MACROS $NO_MISSING_FIELD_INITIALIZERS" >&6; }
+
{ echo "$as_me:$LINENO: checking for sin in -lm" >&5
@@ -35260,7 +35297,7 @@ ac_config_files="$ac_config_files includ
ac_config_files="$ac_config_files include/llvm/Config/AsmParsers.def"
-ac_config_headers="$ac_config_headers include/llvm/Support/DataTypes.h"
+ac_config_headers="$ac_config_headers include/llvm/System/DataTypes.h"
ac_config_files="$ac_config_files Makefile.config"
@@ -35887,7 +35924,7 @@ do
"include/llvm/Config/Targets.def") CONFIG_FILES="$CONFIG_FILES include/llvm/Config/Targets.def" ;;
"include/llvm/Config/AsmPrinters.def") CONFIG_FILES="$CONFIG_FILES include/llvm/Config/AsmPrinters.def" ;;
"include/llvm/Config/AsmParsers.def") CONFIG_FILES="$CONFIG_FILES include/llvm/Config/AsmParsers.def" ;;
- "include/llvm/Support/DataTypes.h") CONFIG_HEADERS="$CONFIG_HEADERS include/llvm/Support/DataTypes.h" ;;
+ "include/llvm/System/DataTypes.h") CONFIG_HEADERS="$CONFIG_HEADERS include/llvm/System/DataTypes.h" ;;
"Makefile.config") CONFIG_FILES="$CONFIG_FILES Makefile.config" ;;
"llvm.spec") CONFIG_FILES="$CONFIG_FILES llvm.spec" ;;
"docs/doxygen.cfg") CONFIG_FILES="$CONFIG_FILES docs/doxygen.cfg" ;;
@@ -36061,11 +36098,11 @@ LLVM_ENUM_TARGETS!$LLVM_ENUM_TARGETS$ac_
LLVM_ENUM_ASM_PRINTERS!$LLVM_ENUM_ASM_PRINTERS$ac_delim
LLVM_ENUM_ASM_PARSERS!$LLVM_ENUM_ASM_PARSERS$ac_delim
ENABLE_CBE_PRINTF_A!$ENABLE_CBE_PRINTF_A$ac_delim
+OPTIMIZE_OPTION!$OPTIMIZE_OPTION$ac_delim
EXTRA_OPTIONS!$EXTRA_OPTIONS$ac_delim
BINUTILS_INCDIR!$BINUTILS_INCDIR$ac_delim
ENABLE_LLVMC_DYNAMIC!$ENABLE_LLVMC_DYNAMIC$ac_delim
ENABLE_LLVMC_DYNAMIC_PLUGINS!$ENABLE_LLVMC_DYNAMIC_PLUGINS$ac_delim
-CXX!$CXX$ac_delim
_ACEOF
if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
@@ -36107,6 +36144,7 @@ _ACEOF
ac_delim='%!_!# '
for ac_last_try in false false false false false :; do
cat >conf$$subs.sed <<_ACEOF
+CXX!$CXX$ac_delim
CXXFLAGS!$CXXFLAGS$ac_delim
ac_ct_CXX!$ac_ct_CXX$ac_delim
NM!$NM$ac_delim
@@ -36167,6 +36205,8 @@ LLVMGCCCOMMAND!$LLVMGCCCOMMAND$ac_delim
LLVMGXXCOMMAND!$LLVMGXXCOMMAND$ac_delim
LLVMGCC!$LLVMGCC$ac_delim
LLVMGXX!$LLVMGXX$ac_delim
+NO_VARIADIC_MACROS!$NO_VARIADIC_MACROS$ac_delim
+NO_MISSING_FIELD_INITIALIZERS!$NO_MISSING_FIELD_INITIALIZERS$ac_delim
USE_UDIS86!$USE_UDIS86$ac_delim
USE_OPROFILE!$USE_OPROFILE$ac_delim
HAVE_PTHREAD!$HAVE_PTHREAD$ac_delim
@@ -36201,7 +36241,7 @@ LIBOBJS!$LIBOBJS$ac_delim
LTLIBOBJS!$LTLIBOBJS$ac_delim
_ACEOF
- if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 92; then
+ if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 95; then
break
elif $ac_last_try; then
{ { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
Modified: vendor/llvm/dist/docs/BitCodeFormat.html
==============================================================================
--- vendor/llvm/dist/docs/BitCodeFormat.html Wed Nov 4 14:19:23 2009 (r198891)
+++ vendor/llvm/dist/docs/BitCodeFormat.html Wed Nov 4 14:58:56 2009 (r198892)
@@ -27,6 +27,15 @@
LLVM IR Encoding
- Basics
+ - MODULE_BLOCK Contents
+ - PARAMATTR_BLOCK Contents
+ - TYPE_BLOCK Contents
+ - CONSTANTS_BLOCK Contents
+ - FUNCTION_BLOCK Contents
+ - TYPE_SYMTAB_BLOCK Contents
+ - VALUE_SYMTAB_BLOCK Contents
+ - METADATA_BLOCK Contents
+ - METADATA_ATTACHMENT Contents
@@ -220,7 +229,7 @@ A bitstream is a sequential series of
@@ -258,7 +267,7 @@ application specific. Nested blocks capt
encoded in it, and various properties are associated with blocks as the file is
parsed. Block definitions allow the reader to efficiently skip blocks
in constant time if the reader wants a summary of blocks, or if it wants to
-efficiently skip data they do not understand. The LLVM IR reader uses this
+efficiently skip data it does not understand. The LLVM IR reader uses this
mechanism to skip function bodies, lazily reading them on demand.
@@ -268,7 +277,8 @@ block. In particular, each block mainta
-- A current abbrev id width. This value starts at 2, and is set every time a
+
- A current abbrev id width. This value starts at 2 at the beginning of
+ the stream, and is set every time a
block record is entered. The block entry specifies the abbrev id width for
the body of the block.
@@ -335,13 +345,14 @@ an even multiple of 32-bits.
-Data records consist of a record code and a number of (up to) 64-bit integer
-values. The interpretation of the code and values is application specific and
-there are multiple different ways to encode a record (with an unabbrev record or
-with an abbreviation). In the LLVM IR format, for example, there is a record
+Data records consist of a record code and a number of (up to) 64-bit
+integer values. The interpretation of the code and values is
+application specific and may vary between different block types.
+Records can be encoded either using an unabbrev record, or with an
+abbreviation. In the LLVM IR format, for example, there is a record
which encodes the target triple of a module. The code is
-MODULE_CODE_TRIPLE, and the values of the record are the ASCII codes
-for the characters in the string.
+MODULE_CODE_TRIPLE, and the values of the record are the
+ASCII codes for the characters in the string.
@@ -358,7 +369,7 @@ Encoding
An UNABBREV_RECORD provides a default fallback encoding, which is both
completely general and extremely inefficient. It can describe an arbitrary
-record by emitting the code and operands as vbrs.
+record by emitting the code and operands as VBRs.
@@ -391,6 +402,11 @@ allows the files to be completely self d
abbreviations is defined below.
+The record code, which is the first field of an abbreviated record,
+may be encoded in the abbreviation definition (as a literal
+operand) or supplied in the abbreviated record (as a Fixed or VBR
+operand value).
+
@@ -409,8 +425,9 @@ emitted.
Abbreviations can be determined dynamically per client, per file. Because the
abbreviations are stored in the bitstream itself, different streams of the same
-format can contain different sets of abbreviations if the specific stream does
-not need it. As a concrete example, LLVM IR files usually emit an abbreviation
+format can contain different sets of abbreviations according to the needs
+of the specific stream.
+As a concrete example, LLVM IR files usually emit an abbreviation
for binary operators. If a specific LLVM module contained no or few binary
operators, the abbreviation does not need to be emitted.
@@ -431,7 +448,8 @@ defined abbreviations in the scope of th
inside this immediate block — it is not visible in subblocks or enclosing
blocks. Abbreviations are implicitly assigned IDs sequentially starting from 4
(the first application-defined abbreviation ID). Any abbreviations defined in a
-BLOCKINFO record receive IDs first, in order, followed by any
+BLOCKINFO record for the particular block type
+receive IDs first, in order, followed by any
abbreviations defined within the block itself. Abbreviated data records
reference this ID to indicate what abbreviation they are invoking.
@@ -461,31 +479,32 @@ emitted as their code, followed by the e
The possible operand encodings are:
-
-- Fixed: The field should be emitted as
+
+- Fixed (code 1): The field should be emitted as
a fixed-width value, whose width is specified by
the operand's extra data.
-- VBR: The field should be emitted as
+
- VBR (code 2): The field should be emitted as
a variable-width value, whose width is
specified by the operand's extra data.
-- Array: This field is an array of values. The array operand
- has no extra data, but expects another operand to follow it which indicates
+
- Array (code 3): This field is an array of values. The array operand
+ has no extra data, but expects another operand to follow it, indicating
the element type of the array. When reading an array in an abbreviated
record, the first integer is a vbr6 that indicates the array length,
followed by the encoded elements of the array. An array may only occur as
the last operand of an abbreviation (except for the one final operand that
gives the array's type).
-- Char6: This field should be emitted as
+
- Char6 (code 4): This field should be emitted as
a char6-encoded value. This operand type takes no
- extra data.
-- Blob: This field is emitted as a vbr6, followed by padding to a
+ extra data. Char6 encoding is normally used as an array element type.
+
+- Blob (code 5): This field is emitted as a vbr6, followed by padding to a
32-bit boundary (for alignment) and an array of 8-bit objects. The array of
bytes is further followed by tail padding to ensure that its total length is
a multiple of 4 bytes. This makes it very efficient for the reader to
decode the data without having to make a copy of it: it can use a pointer to
the data in the mapped in file and poke directly at it. A blob may only
occur as the last operand of an abbreviation.
-
+
For example, target triples in LLVM modules are encoded as a record of the
@@ -517,7 +536,7 @@ as:
- The first value, 4, is the abbreviation ID for this abbreviation.
-- The second value, 2, is the code for TRIPLE in LLVM IR files.
+- The second value, 2, is the record code for TRIPLE records within LLVM IR file MODULE_BLOCK blocks.
- The third value, 4, is the length of the array.
- The rest of the values are the char6 encoded values
for "abcd".
@@ -541,7 +560,7 @@ used for any other string value.
In addition to the basic block structure and record encodings, the bitstream
-also defines specific builtin block types. These block types specify how the
+also defines specific built-in block types. These block types specify how the
stream is to be decoded or other metadata. In the future, new standard blocks
may be added. Block IDs 0-7 are reserved for standard blocks.
@@ -569,7 +588,7 @@ blocks. The currently specified records
-The SETBID record indicates which block ID is being
+The SETBID record (code 1) indicates which block ID is being
described. SETBID records can occur multiple times throughout the
block to change which block ID is being described. There must be
a SETBID record prior to any other records.
@@ -584,13 +603,13 @@ in BLOCKINFO blocks receive abb
in DEFINE_ABBREV.
-The BLOCKNAME can optionally occur in this block. The elements of
-the record are the bytes for the string name of the block. llvm-bcanalyzer uses
+
The BLOCKNAME record (code 2) can optionally occur in this block. The elements of
+the record are the bytes of the string name of the block. llvm-bcanalyzer can use
this to dump out bitcode files symbolically.
-The SETRECORDNAME record can optionally occur in this block. The
-first entry is a record ID number and the rest of the elements of the record are
-the bytes for the string name of the record. llvm-bcanalyzer uses
+
The SETRECORDNAME record (code 3) can also optionally occur in this block. The
+first operand value is a record ID number, and the rest of the elements of the record are
+the bytes for the string name of the record. llvm-bcanalyzer can use
this to dump out bitcode files symbolically.
@@ -626,7 +645,7 @@ Each of the fields are 32-bit fields sto
the rest of the bitcode file fields). The Magic number is always
0x0B17C0DE and the version is currently always 0. The Offset
field is the offset in bytes to the start of the bitcode stream in the file, and
-the Size field is a size in bytes of the stream. CPUType is a target-specific
+the Size field is the size in bytes of the stream. CPUType is a target-specific
value that can be used to encode the CPU of the target.
@@ -681,26 +700,28 @@ When combined with the bitcode magic num
-Variable Width Integers are an efficient way to
-encode arbitrary sized unsigned values, but is an extremely inefficient way to
-encode signed values (as signed values are otherwise treated as maximally large
-unsigned values).
+Variable Width Integer encoding is an efficient way to
+encode arbitrary sized unsigned values, but is an extremely inefficient for
+encoding signed values, as signed values are otherwise treated as maximally large
+unsigned values.
-As such, signed vbr values of a specific width are emitted as follows:
+As such, signed VBR values of a specific width are emitted as follows:
-- Positive values are emitted as vbrs of the specified width, but with their
+
- Positive values are emitted as VBRs of the specified width, but with their
value shifted left by one.
-- Negative values are emitted as vbrs of the specified width, but the negated
+
- Negative values are emitted as VBRs of the specified width, but the negated
value is shifted left by one, and the low bit is set.
-With this encoding, small positive and small negative values can both be emitted
-efficiently.
+With this encoding, small positive and small negative values can both
+be emitted efficiently. Signed VBR encoding is used in
+CST_CODE_INTEGER and CST_CODE_WIDE_INTEGER records
+within CONSTANTS_BLOCK blocks.
@@ -716,21 +737,23 @@ LLVM IR is defined with the following bl
-- 8 — MODULE_BLOCK — This is the top-level block that
+
- 8 — MODULE_BLOCK — This is the top-level block that
contains the entire module, and describes a variety of per-module
information.
-- 9 — PARAMATTR_BLOCK — This enumerates the parameter
+
- 9 — PARAMATTR_BLOCK — This enumerates the parameter
attributes.
-- 10 — TYPE_BLOCK — This describes all of the types in
+
- 10 — TYPE_BLOCK — This describes all of the types in
the module.
-- 11 — CONSTANTS_BLOCK — This describes constants for a
+
- 11 — CONSTANTS_BLOCK — This describes constants for a
module or function.
-- 12 — FUNCTION_BLOCK — This describes a function
+
- 12 — FUNCTION_BLOCK — This describes a function
body.
-- 13 — TYPE_SYMTAB_BLOCK — This describes the type symbol
+
- 13 — TYPE_SYMTAB_BLOCK — This describes the type symbol
table.
-- 14 — VALUE_SYMTAB_BLOCK — This describes a value symbol
+
- 14 — VALUE_SYMTAB_BLOCK — This describes a value symbol
table.
+- 15 — METADATA_BLOCK — This describes metadata items.
+- 16 — METADATA_ATTACHMENT — This contains records associating metadata with function instruction values.
@@ -741,7 +764,387 @@ LLVM IR is defined with the following bl
-
+
The MODULE_BLOCK block (id 8) is the top-level block for LLVM
+bitcode files, and each bitcode file must contain exactly one. In
+addition to records (described below) containing information
+about the module, a MODULE_BLOCK block may contain the
+following sub-blocks:
+
+
+
+
+
+
+
+
+
+
+
+
[VERSION, version#]
+
+
The VERSION record (code 1) contains a single value
+indicating the format version. Only version 0 is supported at this
+time.
+
+
+
+
+
+
+
[TRIPLE, ...string...]
+
+
The TRIPLE record (code 2) contains a variable number of
+values representing the bytes of the target triple
+specification string.
+
+
+
+
+
+
+
[DATALAYOUT, ...string...]
+
+
The DATALAYOUT record (code 3) contains a variable number of
+values representing the bytes of the target datalayout
+specification string.
+
+
+
+
+
+
+
[ASM, ...string...]
+
+
The ASM record (code 4) contains a variable number of
+values representing the bytes of module asm strings, with
+individual assembly blocks separated by newline (ASCII 10) characters.
+
+
+
+
+
+
+
[SECTIONNAME, ...string...]
+
+
The SECTIONNAME record (code 5) contains a variable number
+of values representing the bytes of a single section name
+string. There should be one SECTIONNAME record for each
+section name referenced (e.g., in global variable or function
+section attributes) within the module. These records can be
+referenced by the 1-based index in the section fields of
+GLOBALVAR or FUNCTION records.
+
+
+
+
+
+
+
[DEPLIB, ...string...]
+
+
The DEPLIB record (code 6) contains a variable number of
+values representing the bytes of a single dependent library name
+string, one of the libraries mentioned in a deplibs
+declaration. There should be one DEPLIB record for each
+library name referenced.
+
+
+
+
+
+
+
[GLOBALVAR, pointer type, isconst, initid, linkage, alignment, section, visibility, threadlocal]
+
+
The GLOBALVAR record (code 7) marks the declaration or
+definition of a global variable. The operand fields are:
+
+
+- pointer type: The type index of the pointer type used to point to
+this global variable
+
+- isconst: Non-zero if the variable is treated as constant within
+the module, or zero if it is not
+
+- initid: If non-zero, the value index of the initializer for this
+variable, plus 1.
+
+- linkage: An encoding of the linkage
+type for this variable:
+
+ - external: code 0
+ - weak: code 1
+ - appending: code 2
+ - internal: code 3
+ - linkonce: code 4
+ - dllimport: code 5
+ - dllexport: code 6
+ - extern_weak: code 7
+ - common: code 8
+ - private: code 9
+ - weak_odr: code 10
+ - linkonce_odr: code 11
+ - available_externally: code 12
+ - linker_private: code 13
+
+
+
+- alignment: The logarithm base 2 of the variable's requested
+alignment, plus 1
+
+- section: If non-zero, the 1-based section index in the
+table of MODULE_CODE_SECTIONNAME
+entries.
+
+- visibility: If present, an
+encoding of the visibility of this variable:
+
+ - default: code 0
+ - hidden: code 1
+ - protected: code 2
+
+
+
+- threadlocal: If present and non-zero, indicates that the variable
+is thread_local
+
+
+
+
+
+
+
+
*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***
From rdivacky at FreeBSD.org Wed Nov 4 15:04:33 2009
From: rdivacky at FreeBSD.org (Roman Divacky)
Date: Wed Nov 4 15:04:49 2009
Subject: svn commit: r198893 - in vendor/clang/dist: . clang.xcodeproj docs
docs/tools include/clang-c include/clang/AST
include/clang/Analysis include/clang/Analysis/PathSensitive
include/clang/Analysis/Pa...
Message-ID: <200911041504.nA4F4Xp3035424@svn.freebsd.org>
Author: rdivacky
Date: Wed Nov 4 15:04:32 2009
New Revision: 198893
URL: http://svn.freebsd.org/changeset/base/198893
Log:
Update clang to r86025.
Added:
vendor/clang/dist/include/clang/AST/TemplateBase.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/BugType.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/Checkers/
vendor/clang/dist/include/clang/Analysis/PathSensitive/Checkers/AttrNonNullChecker.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/Checkers/BadCallChecker.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/Checkers/DereferenceChecker.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/Checkers/DivZeroChecker.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/Checkers/UndefinedArgChecker.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/Checkers/UndefinedAssignmentChecker.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/Checkers/VLASizeChecker.h
vendor/clang/dist/include/clang/Frontend/DiagnosticOptions.h
vendor/clang/dist/lib/AST/TemplateBase.cpp
vendor/clang/dist/lib/Analysis/AttrNonNullChecker.cpp
vendor/clang/dist/lib/Analysis/BadCallChecker.cpp
vendor/clang/dist/lib/Analysis/DereferenceChecker.cpp
vendor/clang/dist/lib/Analysis/DivZeroChecker.cpp
vendor/clang/dist/lib/Analysis/NSAutoreleasePoolChecker.cpp
vendor/clang/dist/lib/Analysis/NSErrorChecker.cpp
vendor/clang/dist/lib/Analysis/UndefinedArgChecker.cpp
vendor/clang/dist/lib/Analysis/UndefinedAssignmentChecker.cpp
vendor/clang/dist/lib/Analysis/VLASizeChecker.cpp
vendor/clang/dist/lib/CodeGen/CGException.cpp
vendor/clang/dist/test/CXX/dcl.decl/dcl.meaning/dcl.ref/p5.cpp
vendor/clang/dist/test/CXX/temp/temp.spec/temp.explicit/p10.cpp
vendor/clang/dist/test/CXX/temp/temp.spec/temp.explicit/p12.cpp
vendor/clang/dist/test/CXX/temp/temp.spec/temp.explicit/p5.cpp
vendor/clang/dist/test/CXX/temp/temp.spec/temp.explicit/p6.cpp
vendor/clang/dist/test/CXX/temp/temp.spec/temp.explicit/p7.cpp
vendor/clang/dist/test/CXX/temp/temp.spec/temp.explicit/p8.cpp
vendor/clang/dist/test/CXX/temp/temp.spec/temp.explicit/p9-linkage.cpp
vendor/clang/dist/test/CXX/temp/temp.spec/temp.explicit/p9.cpp
vendor/clang/dist/test/CodeCompletion/macros.c
vendor/clang/dist/test/CodeGen/object-size.c
vendor/clang/dist/test/CodeGenCXX/array-construction.cpp
vendor/clang/dist/test/CodeGenCXX/ptr-to-member-function.cpp
vendor/clang/dist/test/FixIt/fixit-pmem.cpp
vendor/clang/dist/test/Parser/cxx-parse-member-pointer-op.cpp
vendor/clang/dist/test/Preprocessor/has_include.c
vendor/clang/dist/test/Preprocessor/init.c
vendor/clang/dist/test/Preprocessor/macro_undef.c
vendor/clang/dist/test/Preprocessor/stdint.c
vendor/clang/dist/test/Sema/parentheses.c
vendor/clang/dist/test/SemaCXX/ptrtomember-badcall.cpp
vendor/clang/dist/test/SemaCXX/value-initialization.cpp
vendor/clang/dist/test/SemaObjC/conditional-expr-6.m
vendor/clang/dist/test/SemaObjC/property-category-4.m
vendor/clang/dist/test/SemaTemplate/instantiate-non-type-template-parameter.cpp
vendor/clang/dist/test/SemaTemplate/operator-function-id-template.cpp
vendor/clang/dist/test/SemaTemplate/template-id-expr.cpp
vendor/clang/dist/test/SemaTemplate/template-id-printing.cpp
Deleted:
vendor/clang/dist/lib/Analysis/CheckNSError.cpp
Modified:
vendor/clang/dist/CMakeLists.txt
vendor/clang/dist/clang.xcodeproj/project.pbxproj
vendor/clang/dist/docs/LanguageExtensions.html
vendor/clang/dist/docs/tools/clang.pod
vendor/clang/dist/include/clang-c/Index.h
vendor/clang/dist/include/clang/AST/ASTContext.h
vendor/clang/dist/include/clang/AST/CanonicalType.h
vendor/clang/dist/include/clang/AST/Decl.h
vendor/clang/dist/include/clang/AST/DeclGroup.h
vendor/clang/dist/include/clang/AST/DeclNodes.def
vendor/clang/dist/include/clang/AST/DeclObjC.h
vendor/clang/dist/include/clang/AST/DeclTemplate.h
vendor/clang/dist/include/clang/AST/Expr.h
vendor/clang/dist/include/clang/AST/ExprCXX.h
vendor/clang/dist/include/clang/AST/RecordLayout.h
vendor/clang/dist/include/clang/AST/Redeclarable.h
vendor/clang/dist/include/clang/AST/StmtIterator.h
vendor/clang/dist/include/clang/AST/StmtNodes.def
vendor/clang/dist/include/clang/AST/TemplateName.h
vendor/clang/dist/include/clang/AST/Type.h
vendor/clang/dist/include/clang/AST/TypeLoc.h
vendor/clang/dist/include/clang/Analysis/CallGraph.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/AnalysisContext.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/BugReporter.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/Checker.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/GRExprEngine.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/GRState.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/GRTransferFuncs.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/Store.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/SymbolManager.h
vendor/clang/dist/include/clang/Analysis/ProgramPoint.h
vendor/clang/dist/include/clang/Analysis/Visitors/CFGRecStmtDeclVisitor.h
vendor/clang/dist/include/clang/Basic/Builtins.def
vendor/clang/dist/include/clang/Basic/DiagnosticCommonKinds.td
vendor/clang/dist/include/clang/Basic/DiagnosticDriverKinds.td
vendor/clang/dist/include/clang/Basic/DiagnosticFrontendKinds.td
vendor/clang/dist/include/clang/Basic/DiagnosticLexKinds.td
vendor/clang/dist/include/clang/Basic/DiagnosticParseKinds.td
vendor/clang/dist/include/clang/Basic/DiagnosticSemaKinds.td
vendor/clang/dist/include/clang/Basic/OnDiskHashTable.h
vendor/clang/dist/include/clang/Basic/OperatorKinds.h
vendor/clang/dist/include/clang/Basic/PartialDiagnostic.h
vendor/clang/dist/include/clang/Basic/SourceManager.h
vendor/clang/dist/include/clang/Basic/TargetInfo.h
vendor/clang/dist/include/clang/Driver/Options.def
vendor/clang/dist/include/clang/Frontend/ASTUnit.h
vendor/clang/dist/include/clang/Frontend/CompileOptions.h
vendor/clang/dist/include/clang/Frontend/DeclXML.def
vendor/clang/dist/include/clang/Frontend/InitHeaderSearch.h
vendor/clang/dist/include/clang/Frontend/InitPreprocessor.h
vendor/clang/dist/include/clang/Frontend/PCHBitCodes.h
vendor/clang/dist/include/clang/Frontend/PCHReader.h
vendor/clang/dist/include/clang/Frontend/PCHWriter.h
vendor/clang/dist/include/clang/Frontend/TextDiagnosticPrinter.h
vendor/clang/dist/include/clang/Index/Utils.h
vendor/clang/dist/include/clang/Lex/LiteralSupport.h
vendor/clang/dist/include/clang/Lex/Preprocessor.h
vendor/clang/dist/include/clang/Lex/Token.h
vendor/clang/dist/include/clang/Parse/Action.h
vendor/clang/dist/include/clang/Parse/DeclSpec.h
vendor/clang/dist/include/clang/Parse/Parser.h
vendor/clang/dist/include/clang/Sema/CodeCompleteConsumer.h
vendor/clang/dist/lib/AST/ASTContext.cpp
vendor/clang/dist/lib/AST/CMakeLists.txt
vendor/clang/dist/lib/AST/Decl.cpp
vendor/clang/dist/lib/AST/DeclBase.cpp
vendor/clang/dist/lib/AST/DeclCXX.cpp
vendor/clang/dist/lib/AST/DeclObjC.cpp
vendor/clang/dist/lib/AST/DeclPrinter.cpp
vendor/clang/dist/lib/AST/DeclTemplate.cpp
vendor/clang/dist/lib/AST/Expr.cpp
vendor/clang/dist/lib/AST/ExprCXX.cpp
vendor/clang/dist/lib/AST/ExprConstant.cpp
vendor/clang/dist/lib/AST/RecordLayoutBuilder.cpp
vendor/clang/dist/lib/AST/RecordLayoutBuilder.h
vendor/clang/dist/lib/AST/StmtPrinter.cpp
vendor/clang/dist/lib/AST/StmtProfile.cpp
vendor/clang/dist/lib/AST/TemplateName.cpp
vendor/clang/dist/lib/AST/Type.cpp
vendor/clang/dist/lib/Analysis/BasicObjCFoundationChecks.cpp
vendor/clang/dist/lib/Analysis/BasicObjCFoundationChecks.h
vendor/clang/dist/lib/Analysis/BasicStore.cpp
vendor/clang/dist/lib/Analysis/CFRefCount.cpp
vendor/clang/dist/lib/Analysis/CMakeLists.txt
vendor/clang/dist/lib/Analysis/CallGraph.cpp
vendor/clang/dist/lib/Analysis/CheckObjCUnusedIVars.cpp
vendor/clang/dist/lib/Analysis/GRExprEngine.cpp
vendor/clang/dist/lib/Analysis/GRExprEngineInternalChecks.cpp
vendor/clang/dist/lib/Analysis/RegionStore.cpp
vendor/clang/dist/lib/Basic/CMakeLists.txt
vendor/clang/dist/lib/Basic/IdentifierTable.cpp
vendor/clang/dist/lib/Basic/TargetInfo.cpp
vendor/clang/dist/lib/Basic/Targets.cpp
vendor/clang/dist/lib/CodeGen/CGBuiltin.cpp
vendor/clang/dist/lib/CodeGen/CGCXX.cpp
vendor/clang/dist/lib/CodeGen/CGCall.cpp
vendor/clang/dist/lib/CodeGen/CGDecl.cpp
vendor/clang/dist/lib/CodeGen/CGExpr.cpp
vendor/clang/dist/lib/CodeGen/CGExprAgg.cpp
vendor/clang/dist/lib/CodeGen/CGExprConstant.cpp
vendor/clang/dist/lib/CodeGen/CGExprScalar.cpp
vendor/clang/dist/lib/CodeGen/CGObjC.cpp
vendor/clang/dist/lib/CodeGen/CGRecordLayoutBuilder.h
vendor/clang/dist/lib/CodeGen/CGRtti.cpp
vendor/clang/dist/lib/CodeGen/CGStmt.cpp
vendor/clang/dist/lib/CodeGen/CGValue.h
vendor/clang/dist/lib/CodeGen/CGVtable.cpp
vendor/clang/dist/lib/CodeGen/CMakeLists.txt
vendor/clang/dist/lib/CodeGen/CodeGenFunction.cpp
vendor/clang/dist/lib/CodeGen/CodeGenFunction.h
vendor/clang/dist/lib/CodeGen/CodeGenModule.cpp
vendor/clang/dist/lib/CodeGen/CodeGenTypes.cpp
vendor/clang/dist/lib/CodeGen/Mangle.cpp
vendor/clang/dist/lib/CodeGen/Mangle.h
vendor/clang/dist/lib/Driver/Tools.cpp
vendor/clang/dist/lib/Driver/Types.cpp
vendor/clang/dist/lib/Frontend/ASTConsumers.cpp
vendor/clang/dist/lib/Frontend/AnalysisConsumer.cpp
vendor/clang/dist/lib/Frontend/InitHeaderSearch.cpp
vendor/clang/dist/lib/Frontend/InitPreprocessor.cpp
vendor/clang/dist/lib/Frontend/PCHReader.cpp
vendor/clang/dist/lib/Frontend/PCHReaderDecl.cpp
vendor/clang/dist/lib/Frontend/PCHReaderStmt.cpp
vendor/clang/dist/lib/Frontend/PCHWriter.cpp
vendor/clang/dist/lib/Frontend/PCHWriterDecl.cpp
vendor/clang/dist/lib/Frontend/PCHWriterStmt.cpp
vendor/clang/dist/lib/Frontend/PrintPreprocessedOutput.cpp
vendor/clang/dist/lib/Frontend/RewriteObjC.cpp
vendor/clang/dist/lib/Frontend/TextDiagnosticPrinter.cpp
vendor/clang/dist/lib/Headers/CMakeLists.txt
vendor/clang/dist/lib/Headers/stdint.h
vendor/clang/dist/lib/Index/ResolveLocation.cpp
vendor/clang/dist/lib/Lex/HeaderMap.cpp
vendor/clang/dist/lib/Lex/PPDirectives.cpp
vendor/clang/dist/lib/Lex/PPExpressions.cpp
vendor/clang/dist/lib/Lex/PPMacroExpansion.cpp
vendor/clang/dist/lib/Parse/AttributeList.cpp
vendor/clang/dist/lib/Parse/DeclSpec.cpp
vendor/clang/dist/lib/Parse/MinimalAction.cpp
vendor/clang/dist/lib/Parse/ParseDecl.cpp
vendor/clang/dist/lib/Parse/ParseDeclCXX.cpp
vendor/clang/dist/lib/Parse/ParseExpr.cpp
vendor/clang/dist/lib/Parse/ParseExprCXX.cpp
vendor/clang/dist/lib/Parse/ParseObjc.cpp
vendor/clang/dist/lib/Parse/ParseStmt.cpp
vendor/clang/dist/lib/Parse/ParseTemplate.cpp
vendor/clang/dist/lib/Parse/Parser.cpp
vendor/clang/dist/lib/Sema/CodeCompleteConsumer.cpp
vendor/clang/dist/lib/Sema/Sema.cpp
vendor/clang/dist/lib/Sema/Sema.h
vendor/clang/dist/lib/Sema/SemaCXXCast.cpp
vendor/clang/dist/lib/Sema/SemaChecking.cpp
vendor/clang/dist/lib/Sema/SemaCodeComplete.cpp
vendor/clang/dist/lib/Sema/SemaDecl.cpp
vendor/clang/dist/lib/Sema/SemaDeclAttr.cpp
vendor/clang/dist/lib/Sema/SemaDeclCXX.cpp
vendor/clang/dist/lib/Sema/SemaDeclObjC.cpp
vendor/clang/dist/lib/Sema/SemaExpr.cpp
vendor/clang/dist/lib/Sema/SemaExprCXX.cpp
vendor/clang/dist/lib/Sema/SemaLookup.cpp
vendor/clang/dist/lib/Sema/SemaOverload.cpp
vendor/clang/dist/lib/Sema/SemaStmt.cpp
vendor/clang/dist/lib/Sema/SemaTemplate.cpp
vendor/clang/dist/lib/Sema/SemaTemplateDeduction.cpp
vendor/clang/dist/lib/Sema/SemaTemplateInstantiate.cpp
vendor/clang/dist/lib/Sema/SemaTemplateInstantiateDecl.cpp
vendor/clang/dist/lib/Sema/SemaType.cpp
vendor/clang/dist/lib/Sema/TreeTransform.h
vendor/clang/dist/test/Analysis/misc-ps-eager-assume.m
vendor/clang/dist/test/Analysis/misc-ps-region-store.m
vendor/clang/dist/test/Analysis/misc-ps.m
vendor/clang/dist/test/Analysis/outofbound.c
vendor/clang/dist/test/Analysis/retain-release-gc-only.m
vendor/clang/dist/test/Analysis/retain-release.m
vendor/clang/dist/test/Analysis/uninit-vals-ps-region.c
vendor/clang/dist/test/Analysis/unused-ivars.m
vendor/clang/dist/test/CMakeLists.txt
vendor/clang/dist/test/CXX/basic/basic.lookup/basic.lookup.unqual/p14.cpp
vendor/clang/dist/test/CXX/basic/basic.lookup/basic.lookup.unqual/p15.cpp
vendor/clang/dist/test/CXX/class/class.union/p1.cpp
vendor/clang/dist/test/CXX/dcl.dcl/dcl.spec/dcl.fct.spec/p3.cpp
vendor/clang/dist/test/CXX/dcl.dcl/dcl.spec/dcl.fct.spec/p4.cpp
vendor/clang/dist/test/CXX/dcl.dcl/dcl.spec/dcl.fct.spec/p6.cpp
vendor/clang/dist/test/CXX/dcl.dcl/dcl.spec/dcl.stc/p10.cpp
vendor/clang/dist/test/CXX/dcl.dcl/dcl.spec/dcl.typedef/p4.cpp
vendor/clang/dist/test/CXX/temp/temp.decls/temp.class.spec/p6.cpp
vendor/clang/dist/test/CXX/temp/temp.decls/temp.friend/p5.cpp
vendor/clang/dist/test/CXX/temp/temp.param/p14.cpp
vendor/clang/dist/test/CXX/temp/temp.res/temp.dep.res/temp.point/p1.cpp
vendor/clang/dist/test/CXX/temp/temp.spec/temp.expl.spec/p3.cpp
vendor/clang/dist/test/CXX/temp/temp.spec/temp.explicit/p3.cpp
vendor/clang/dist/test/CodeGen/2008-07-21-mixed-var-fn-decl.c
vendor/clang/dist/test/CodeGen/2008-07-29-override-alias-decl.c
vendor/clang/dist/test/CodeGen/asm-inout.c
vendor/clang/dist/test/CodeGen/blocks-2.c
vendor/clang/dist/test/CodeGen/builtin-unwind-init.c
vendor/clang/dist/test/CodeGen/cast-to-union.c
vendor/clang/dist/test/CodeGen/function-attributes.c
vendor/clang/dist/test/CodeGen/indirect-goto.c
vendor/clang/dist/test/CodeGen/mangle.c
vendor/clang/dist/test/CodeGen/union-init2.c
vendor/clang/dist/test/CodeGen/volatile.c
vendor/clang/dist/test/CodeGenCXX/ptr-to-datamember.cpp
vendor/clang/dist/test/CodeGenCXX/temporaries.cpp
vendor/clang/dist/test/CodeGenCXX/virt.cpp
vendor/clang/dist/test/CodeGenObjC/PR4894-recursive-debug-crash.m
vendor/clang/dist/test/CodeGenObjC/encode-test-2.m
vendor/clang/dist/test/CodeGenObjC/synthesize_ivar.m
vendor/clang/dist/test/Coverage/objc-language-features.inc
vendor/clang/dist/test/Coverage/targets.c
vendor/clang/dist/test/Driver/analyze.c
vendor/clang/dist/test/Driver/ccc-add-args.c
vendor/clang/dist/test/Driver/hello.c
vendor/clang/dist/test/Driver/phases.c
vendor/clang/dist/test/Driver/qa_override.c
vendor/clang/dist/test/Driver/std.c
vendor/clang/dist/test/Frontend/darwin-version.c
vendor/clang/dist/test/Frontend/dependency-gen.c
vendor/clang/dist/test/Lexer/block_cmt_end.c
vendor/clang/dist/test/Makefile
vendor/clang/dist/test/Misc/message-length.c
vendor/clang/dist/test/PCH/pr4489.c
vendor/clang/dist/test/Parser/cxx-template-decl.cpp
vendor/clang/dist/test/Preprocessor/assembler-with-cpp.c
vendor/clang/dist/test/Preprocessor/c99-6_10_3_3_p4.c
vendor/clang/dist/test/Preprocessor/c99-6_10_3_4_p5.c
vendor/clang/dist/test/Preprocessor/c99-6_10_3_4_p6.c
vendor/clang/dist/test/Preprocessor/c99-6_10_3_4_p7.c
vendor/clang/dist/test/Preprocessor/c99-6_10_3_4_p9.c
vendor/clang/dist/test/Preprocessor/comment_save.c
vendor/clang/dist/test/Preprocessor/comment_save_macro.c
vendor/clang/dist/test/Preprocessor/line-directive.c
vendor/clang/dist/test/Preprocessor/macro_disable3.c
vendor/clang/dist/test/Preprocessor/macro_paste_mscomment.c
vendor/clang/dist/test/Preprocessor/macro_rescan_varargs.c
vendor/clang/dist/test/Preprocessor/macro_rparen_scan2.c
vendor/clang/dist/test/Preprocessor/output_paste_avoid.c
vendor/clang/dist/test/Preprocessor/stringize_misc.c
vendor/clang/dist/test/Sema/attr-deprecated.c
vendor/clang/dist/test/Sema/callingconv.c
vendor/clang/dist/test/Sema/constant-builtins-2.c
vendor/clang/dist/test/Sema/decl-invalid.c
vendor/clang/dist/test/Sema/format-strings.c
vendor/clang/dist/test/Sema/init.c
vendor/clang/dist/test/Sema/offsetof.c
vendor/clang/dist/test/Sema/return-noreturn.c
vendor/clang/dist/test/Sema/return.c
vendor/clang/dist/test/Sema/statements.c
vendor/clang/dist/test/Sema/stdcall-fastcall.c
vendor/clang/dist/test/Sema/vector-init.c
vendor/clang/dist/test/SemaCXX/constructor.cpp
vendor/clang/dist/test/SemaCXX/implicit-int.cpp
vendor/clang/dist/test/SemaCXX/invalid-member-expr.cpp
vendor/clang/dist/test/SemaCXX/invalid-template-specifier.cpp
vendor/clang/dist/test/SemaCXX/nested-name-spec.cpp
vendor/clang/dist/test/SemaCXX/new-delete.cpp
vendor/clang/dist/test/SemaCXX/overloaded-operator.cpp
vendor/clang/dist/test/SemaCXX/typedef-redecl.cpp
vendor/clang/dist/test/SemaObjC/continuation-class-err.m
vendor/clang/dist/test/SemaObjC/id-isa-ref.m
vendor/clang/dist/test/SemaObjC/return.m
vendor/clang/dist/test/SemaObjCXX/overload.mm
vendor/clang/dist/test/SemaObjCXX/references.mm
vendor/clang/dist/test/SemaTemplate/class-template-spec.cpp
vendor/clang/dist/test/SemaTemplate/constructor-template.cpp
vendor/clang/dist/test/SemaTemplate/copy-ctor-assign.cpp
vendor/clang/dist/test/SemaTemplate/default-expr-arguments.cpp
vendor/clang/dist/test/SemaTemplate/ext-vector-type.cpp
vendor/clang/dist/test/SemaTemplate/friend-template.cpp
vendor/clang/dist/test/SemaTemplate/instantiate-cast.cpp
vendor/clang/dist/test/SemaTemplate/instantiate-declref-ice.cpp
vendor/clang/dist/test/SemaTemplate/instantiate-declref.cpp
vendor/clang/dist/test/SemaTemplate/instantiate-function-1.mm
vendor/clang/dist/test/SemaTemplate/instantiate-method.cpp
vendor/clang/dist/test/SemaTemplate/instantiate-subscript.cpp
vendor/clang/dist/test/SemaTemplate/member-template-access-expr.cpp
vendor/clang/dist/test/SemaTemplate/nested-name-spec-template.cpp
vendor/clang/dist/test/SemaTemplate/nested-template.cpp
vendor/clang/dist/test/lit.site.cfg.in
vendor/clang/dist/tools/CIndex/CIndex.cpp
vendor/clang/dist/tools/CIndex/CIndex.exports
vendor/clang/dist/tools/CIndex/CMakeLists.txt
vendor/clang/dist/tools/CMakeLists.txt
vendor/clang/dist/tools/c-index-test/c-index-test.c
vendor/clang/dist/tools/clang-cc/clang-cc.cpp
vendor/clang/dist/tools/wpa/clang-wpa.cpp
vendor/clang/dist/www/UniversalDriver.html
vendor/clang/dist/www/analyzer/latest_checker.html.incl
vendor/clang/dist/www/cxx_status.html
Modified: vendor/clang/dist/CMakeLists.txt
==============================================================================
--- vendor/clang/dist/CMakeLists.txt Wed Nov 4 14:58:56 2009 (r198892)
+++ vendor/clang/dist/CMakeLists.txt Wed Nov 4 15:04:32 2009 (r198893)
@@ -65,7 +65,7 @@ macro(add_clang_library name)
set_target_properties(${name} PROPERTIES COMPILE_FLAGS ${cflag})
endif(MSVC)
install(TARGETS ${name}
- LIBRARY DESTINATION lib
+ LIBRARY DESTINATION lib${LLVM_LIBDIR_SUFFIX}
ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX})
endmacro(add_clang_library)
@@ -83,8 +83,12 @@ include_directories(
${CMAKE_CURRENT_BINARY_DIR}/include
)
-install(DIRECTORY include
- DESTINATION .
+install(DIRECTORY include/
+ DESTINATION include
+ FILES_MATCHING
+ PATTERN "*.def"
+ PATTERN "*.h"
+ PATTERN "*.td"
PATTERN ".svn" EXCLUDE
)
Modified: vendor/clang/dist/clang.xcodeproj/project.pbxproj
==============================================================================
--- vendor/clang/dist/clang.xcodeproj/project.pbxproj Wed Nov 4 14:58:56 2009 (r198892)
+++ vendor/clang/dist/clang.xcodeproj/project.pbxproj Wed Nov 4 15:04:32 2009 (r198893)
@@ -49,6 +49,7 @@
1ADF47AF0F782C3200E48A8A /* SemaTemplateInstantiateDecl.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ADF47AE0F782C3200E48A8A /* SemaTemplateInstantiateDecl.cpp */; };
1AE4EE3E103B89ED00888A23 /* StmtProfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AE4EE3D103B89ED00888A23 /* StmtProfile.cpp */; };
1AE4EE40103B8A0A00888A23 /* TargetABIInfo.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AE4EE3F103B8A0A00888A23 /* TargetABIInfo.cpp */; };
+ 1AF1B50F109A4FB800AFAFAC /* CGException.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AF1B50E109A4FB800AFAFAC /* CGException.cpp */; };
1AFEF4070F8A6B2300476F2B /* clang-cc.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AFEF4050F8A6B2300476F2B /* clang-cc.cpp */; };
1AFF8AE31012BFC900D248DA /* CGRecordLayoutBuilder.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AFF8AE11012BFC900D248DA /* CGRecordLayoutBuilder.cpp */; };
3507E4C20E27FE2D00FB7B57 /* CheckObjCInstMethSignature.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3507E4C10E27FE2D00FB7B57 /* CheckObjCInstMethSignature.cpp */; };
@@ -399,6 +400,7 @@
1AE4EE3B103B89CA00888A23 /* TreeTransform.h */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.c.h; name = TreeTransform.h; path = lib/Sema/TreeTransform.h; sourceTree = "
"; tabWidth = 2; };
1AE4EE3D103B89ED00888A23 /* StmtProfile.cpp */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.cpp.cpp; name = StmtProfile.cpp; path = lib/AST/StmtProfile.cpp; sourceTree = ""; tabWidth = 2; };
1AE4EE3F103B8A0A00888A23 /* TargetABIInfo.cpp */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.cpp.cpp; name = TargetABIInfo.cpp; path = lib/CodeGen/TargetABIInfo.cpp; sourceTree = ""; tabWidth = 2; };
+ 1AF1B50E109A4FB800AFAFAC /* CGException.cpp */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.cpp.cpp; name = CGException.cpp; path = lib/CodeGen/CGException.cpp; sourceTree = ""; tabWidth = 2; };
1AFEF4050F8A6B2300476F2B /* clang-cc.cpp */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.cpp.cpp; name = "clang-cc.cpp"; path = "tools/clang-cc/clang-cc.cpp"; sourceTree = ""; tabWidth = 2; };
1AFF8AE11012BFC900D248DA /* CGRecordLayoutBuilder.cpp */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.cpp.cpp; name = CGRecordLayoutBuilder.cpp; path = lib/CodeGen/CGRecordLayoutBuilder.cpp; sourceTree = ""; tabWidth = 2; };
1AFF8AE21012BFC900D248DA /* CGRecordLayoutBuilder.h */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.c.h; name = CGRecordLayoutBuilder.h; path = lib/CodeGen/CGRecordLayoutBuilder.h; sourceTree = ""; tabWidth = 2; };
@@ -515,6 +517,13 @@
9012911C1048068D0083456D /* ASTUnit.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ASTUnit.cpp; path = lib/Frontend/ASTUnit.cpp; sourceTree = ""; };
9012911F104812F90083456D /* CIndex.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CIndex.cpp; path = tools/CIndex/CIndex.cpp; sourceTree = ""; };
90129120104812F90083456D /* CIndex.exports */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = CIndex.exports; path = tools/CIndex/CIndex.exports; sourceTree = ""; };
+ 904753791096376F00CBDDDD /* CXXInheritance.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CXXInheritance.h; path = clang/AST/CXXInheritance.h; sourceTree = ""; };
+ 9047537A1096376F00CBDDDD /* Redeclarable.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Redeclarable.h; path = clang/AST/Redeclarable.h; sourceTree = ""; };
+ 9047537B1096376F00CBDDDD /* TypeLoc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TypeLoc.h; path = clang/AST/TypeLoc.h; sourceTree = ""; };
+ 9047537C1096376F00CBDDDD /* TypeLocBuilder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TypeLocBuilder.h; path = clang/AST/TypeLocBuilder.h; sourceTree = ""; };
+ 9047537D1096376F00CBDDDD /* TypeLocNodes.def */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = TypeLocNodes.def; path = clang/AST/TypeLocNodes.def; sourceTree = ""; };
+ 9047537E1096376F00CBDDDD /* TypeLocVisitor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TypeLocVisitor.h; path = clang/AST/TypeLocVisitor.h; sourceTree = ""; };
+ 9047537F1096376F00CBDDDD /* TypeVisitor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = TypeVisitor.h; path = clang/AST/TypeVisitor.h; sourceTree = ""; };
9063F2210F9E8BDF002F7251 /* ExternalSemaSource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ExternalSemaSource.h; path = clang/Sema/ExternalSemaSource.h; sourceTree = ""; };
9063F2220F9E8BDF002F7251 /* SemaConsumer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SemaConsumer.h; path = clang/Sema/SemaConsumer.h; sourceTree = ""; };
9063F2280F9E911F002F7251 /* OnDiskHashTable.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = OnDiskHashTable.h; sourceTree = ""; };
@@ -1257,6 +1266,7 @@
35A3E7000DD3874400757F74 /* CGDebugInfo.cpp */,
35A3E7010DD3874400757F74 /* CGDebugInfo.h */,
DE4264FB0C113592005A861D /* CGDecl.cpp */,
+ 1AF1B50E109A4FB800AFAFAC /* CGException.cpp */,
DE4772FB0C10EAEC002239E8 /* CGExpr.cpp */,
DEF2EFF20C6CDD74000C4259 /* CGExprAgg.cpp */,
DE224FF70C7AA98800D370A5 /* CGExprComplex.cpp */,
@@ -1298,6 +1308,13 @@
DEC8D98B0A9433BC00353FCA /* AST */ = {
isa = PBXGroup;
children = (
+ 904753791096376F00CBDDDD /* CXXInheritance.h */,
+ 9047537A1096376F00CBDDDD /* Redeclarable.h */,
+ 9047537B1096376F00CBDDDD /* TypeLoc.h */,
+ 9047537C1096376F00CBDDDD /* TypeLocBuilder.h */,
+ 9047537D1096376F00CBDDDD /* TypeLocNodes.def */,
+ 9047537E1096376F00CBDDDD /* TypeLocVisitor.h */,
+ 9047537F1096376F00CBDDDD /* TypeVisitor.h */,
DECB78540FA58F5500F5FBC7 /* AccessSpecifier.h */,
DE613EF30E0E148D00B05B79 /* APValue.h */,
DEC8D9A30A94346E00353FCA /* AST.h */,
@@ -1901,6 +1918,7 @@
1A535ED9107BC45E000C3AE7 /* CXXInheritance.cpp in Sources */,
1A6C01F7108128710072DEE4 /* CGRtti.cpp in Sources */,
1A81AA19108144F40094E50B /* CGVtable.cpp in Sources */,
+ 1AF1B50F109A4FB800AFAFAC /* CGException.cpp in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Modified: vendor/clang/dist/docs/LanguageExtensions.html
==============================================================================
--- vendor/clang/dist/docs/LanguageExtensions.html Wed Nov 4 14:58:56 2009 (r198892)
+++ vendor/clang/dist/docs/LanguageExtensions.html Wed Nov 4 15:04:32 2009 (r198893)
@@ -20,6 +20,7 @@ td {
- Introduction
- Feature Checking Macros
+- Include File Checking Macros
- Builtin Macros
- Vectors and Extended Vectors
- Blocks
@@ -112,6 +113,69 @@ can be used like this:
The feature tag is described along with the language feature below.
+
+Include File Checking Macros
+
+
+Not all developments systems have the same include files.
+The __has_include and
+__has_include_next macros allow you to
+check for the existence of an include file before doing
+a possibly failing #include directive.
+
+
+__has_include
+
+
+This function-like macro takes a single file name string argument that
+is the name of an include file. It evaluates to 1 if the file can
+be found using the include paths, or 0 otherwise:
+
+
+
+// Note the two possible file name string formats.
+#if __has_include("myinclude.h") && __has_include(<stdint.h>)
+# include "myinclude.h"
+#endif
+
+// To avoid problem with non-clang compilers not having this macro.
+#if defined(__has_include) && __has_include("myinclude.h")
+# include "myinclude.h"
+#endif
+
+
+
+To test for this feature, use #if defined(__has_include).
+
+
+__has_include_next
+
+
+This function-like macro takes a single file name string argument that
+is the name of an include file. It is like __has_include except that it
+looks for the second instance of the given file found in the include
+paths. It evaluates to 1 if the second instance of the file can
+be found using the include paths, or 0 otherwise:
+
+
+
+// Note the two possible file name string formats.
+#if __has_include_next("myinclude.h") && __has_include_next(<stdint.h>)
+# include_next "myinclude.h"
+#endif
+
+// To avoid problem with non-clang compilers not having this macro.
+#if defined(__has_include_next) && __has_include_next("myinclude.h")
+# include_next "myinclude.h"
+#endif
+
+
+
+Note that __has_include_next, like the GNU extension
+#include_next directive, is intended for use in headers only,
+and will issue a warning if used in the top-level compilation
+file. A warning will also be issued if an absolute path
+is used in the file argument.
Builtin Macros
Modified: vendor/clang/dist/docs/tools/clang.pod
==============================================================================
--- vendor/clang/dist/docs/tools/clang.pod Wed Nov 4 14:58:56 2009 (r198892)
+++ vendor/clang/dist/docs/tools/clang.pod Wed Nov 4 15:04:32 2009 (r198893)
@@ -424,6 +424,10 @@ Add the specified directory to the searc
Do not search the standard system directories for include files.
+=item B<-nobuiltininc>
+
+Do not search clang's builtin directory for include files.
+
=cut
## TODO, but do we really want people using this stuff?
Modified: vendor/clang/dist/include/clang-c/Index.h
==============================================================================
--- vendor/clang/dist/include/clang-c/Index.h Wed Nov 4 14:58:56 2009 (r198892)
+++ vendor/clang/dist/include/clang-c/Index.h Wed Nov 4 15:04:32 2009 (r198893)
@@ -16,10 +16,23 @@
#ifndef CLANG_C_INDEX_H
#define CLANG_C_INDEX_H
+#include
+
#ifdef __cplusplus
extern "C" {
#endif
+/* MSVC DLL import/export. */
+#ifdef _MSC_VER
+ #ifdef _CINDEX_LIB_
+ #define CINDEX_LINKAGE __declspec(dllexport)
+ #else
+ #define CINDEX_LINKAGE __declspec(dllimport)
+ #endif
+#else
+ #define CINDEX_LINKAGE
+#endif
+
/*
Clang indeX abstractions. The backing store for the following API's will be
clangs AST file (currently based on PCH). AST files are created as follows:
@@ -33,6 +46,7 @@ typedef void *CXIndex; /* An
typedef void *CXTranslationUnit; /* A translation unit instance. */
+typedef void *CXFile; /* A source file */
typedef void *CXDecl; /* A specific declaration within a translation unit. */
typedef void *CXStmt; /* A specific statement within a function/method */
@@ -138,22 +152,22 @@ typedef void *CXEntity;
* -include-pch) allows 'excludeDeclsFromPCH' to remove redundant callbacks
* (which gives the indexer the same performance benefit as the compiler).
*/
-CXIndex clang_createIndex(int excludeDeclarationsFromPCH,
+CINDEX_LINKAGE CXIndex clang_createIndex(int excludeDeclarationsFromPCH,
int displayDiagnostics);
-void clang_disposeIndex(CXIndex);
+CINDEX_LINKAGE void clang_disposeIndex(CXIndex);
-const char *clang_getTranslationUnitSpelling(CXTranslationUnit CTUnit);
+CINDEX_LINKAGE const char *clang_getTranslationUnitSpelling(CXTranslationUnit CTUnit);
/*
* \brief Create a translation unit from an AST file (-emit-ast).
*/
-CXTranslationUnit clang_createTranslationUnit(
+CINDEX_LINKAGE CXTranslationUnit clang_createTranslationUnit(
CXIndex, const char *ast_filename
);
/**
* \brief Destroy the specified CXTranslationUnit object.
*/
-void clang_disposeTranslationUnit(CXTranslationUnit);
+CINDEX_LINKAGE void clang_disposeTranslationUnit(CXTranslationUnit);
/**
* \brief Return the CXTranslationUnit for a given source file and the provided
@@ -170,7 +184,7 @@ void clang_disposeTranslationUnit(CXTran
* '-o